|
1 /* |
|
2 * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: |
|
15 * |
|
16 */ |
|
17 |
|
18 #include <hbdataformmodelitem.h> |
|
19 #include <QTranslator> |
|
20 #include <QLocale> |
|
21 #include <QApplication> |
|
22 #include <cpitemdatahelper.h> |
|
23 #include "cpbarringplugingroup.h" |
|
24 #include "cpplugincommon.h" |
|
25 #include "cpphonenotes.h" |
|
26 #include "cppluginlogging.h" |
|
27 |
|
28 /*! |
|
29 CpBarringPluginGroup::CpBarringPluginGroup. |
|
30 */ |
|
31 CpBarringPluginGroup::CpBarringPluginGroup(CpItemDataHelper &helper) |
|
32 :CpSettingFormItemData(HbDataFormModelItem::GroupItem, hbTrId("Call barring"),0), |
|
33 m_helper(helper) |
|
34 { |
|
35 DPRINT << ": IN"; |
|
36 |
|
37 // Localization file loading |
|
38 QTranslator translator; |
|
39 QString lang = QLocale::system().name(); |
|
40 QString path = "z:/resource/qt/translations/"; |
|
41 DPRINT << ": loading translation: " << QString(path + "telephone_cp_" + lang); |
|
42 bool translatorLoaded = translator.load(path + "telephone_cp_" + lang); |
|
43 DPRINT << ": translator loaded: " << translatorLoaded; |
|
44 if (translatorLoaded) { |
|
45 qApp->installTranslator(&translator); |
|
46 DPRINT << ": translator installed"; |
|
47 } |
|
48 |
|
49 DPRINT << ": OUT"; |
|
50 } |
|
51 |
|
52 /*! |
|
53 CpBarringPluginGroup::~CpBarringPluginGroup. |
|
54 */ |
|
55 CpBarringPluginGroup::~CpBarringPluginGroup() |
|
56 { |
|
57 DPRINT << ": IN"; |
|
58 DPRINT << ": OUT"; |
|
59 } |
|
60 |
|
61 // End of File. |