201029
authorhgs
Fri, 23 Jul 2010 16:30:56 +0530
changeset 49 c34c36d1c835
parent 47 d316aecb87fd
child 52 6e38e48ee756
201029
deviceupdatesui/deviceupdates/inc/dminforetrieval.h
deviceupdatesui/deviceupdates/src/dmadvancedview.cpp
deviceupdatesui/deviceupdates/src/dminforetrieval.cpp
deviceupdatesui/deviceupdates/src/serversettingsview.cpp
--- a/deviceupdatesui/deviceupdates/inc/dminforetrieval.h	Tue Jul 13 04:01:20 2010 +0530
+++ b/deviceupdatesui/deviceupdates/inc/dminforetrieval.h	Fri Jul 23 16:30:56 2010 +0530
@@ -44,8 +44,9 @@
        int profilescount();
       int profileinfo(int profilelistnum, QStringList& itemtext, int& icon, bool& lock);       
        void setDefaultProfile(int listitem);      
-       bool Isprofilelocked(int profilelistnum/*, bool& lock*/);
-       bool Isdefaultprofile(int profilelistnum/*, bool& defaultprofile*/);
+       bool Isprofilelocked(int profilelistnum);
+       bool Isdefaultprofile(int profilelistnum);
+       bool isProfileDeleteAllowed(int profilelistnum);
        void profileTransport(int profilelistnum, int& transport);
        TInt DeleteProfile( TInt& aIndex );
        bool createNewprofile();       
--- a/deviceupdatesui/deviceupdates/src/dmadvancedview.cpp	Tue Jul 13 04:01:20 2010 +0530
+++ b/deviceupdatesui/deviceupdates/src/dmadvancedview.cpp	Fri Jul 23 16:30:56 2010 +0530
@@ -75,7 +75,8 @@
             connect(defaultprofileAction, SIGNAL(triggered()), this,
                     SLOT(defaultMenuItemSelected()));
             }
-        if (!dminfo->Isprofilelocked(currentselecteditem))
+        if (!dminfo->Isprofilelocked(currentselecteditem) && 
+                     dminfo->isProfileDeleteAllowed(currentselecteditem) )
             {
             deleteaction = csmenu->addAction(hbTrId(
                     "txt_device_update_menu_delete"));
--- a/deviceupdatesui/deviceupdates/src/dminforetrieval.cpp	Tue Jul 13 04:01:20 2010 +0530
+++ b/deviceupdatesui/deviceupdates/src/dminforetrieval.cpp	Fri Jul 23 16:30:56 2010 +0530
@@ -247,6 +247,19 @@
     return defaultprofile;
     }
 
+bool DmInfo::isProfileDeleteAllowed(int profilelistnum)
+    {
+    bool deleteAllowed = false;
+    if(profilelistnum >= 0 && iProfileList->Count() > 0)
+        {        
+        if(( iProfileList->At( profilelistnum ).iDeleteAllowed))
+            {
+        deleteAllowed = true;
+            }                  
+        }
+    return deleteAllowed;
+    }
+
 void DmInfo::profileTransport(int profilelistnum, int& transport)
     {
     if(profilelistnum >= 0 && profilelistnum < profilescount())
--- a/deviceupdatesui/deviceupdates/src/serversettingsview.cpp	Tue Jul 13 04:01:20 2010 +0530
+++ b/deviceupdatesui/deviceupdates/src/serversettingsview.cpp	Fri Jul 23 16:30:56 2010 +0530
@@ -74,12 +74,12 @@
         serverpwd->setContentWidgetData(QString("echoMode"),HbLineEdit::Password );
         serverpwd->setContentWidgetData(QString("text"), settingdatalist[2]);                
         QStringList sList;
-        sList <<hbTrId("txt_device_update_button_internet");
-        sList<<hbTrId("txt_device_update_button_bluetooth");        
+        sList <<hbTrId("txt_deviceupdate_setlabel_to_update_your_val_inter");
+        sList<<hbTrId("txt_deviceupdate_setlabel_to_update_your_val_bluet");        
         sessionmode->setContentWidgetData(QString("text"), sList[0]);//Internet selected
         sessionmode->setContentWidgetData(QString("additionalText"), sList[1]);
         
-        apdata.append(hbTrId("txt_device_update_setlabel_access_point_val_defaul"));
+        apdata.append(hbTrId("txt_deviceupdate_setlabel_access_point_val_default"));
         accesspoint->setContentWidgetData(QString("items"), apdata);
         currentiapindex = currentap;
         if(currentap >= 0)
@@ -95,8 +95,8 @@
         userpwd->setContentWidgetData(QString("echoMode"),HbLineEdit::Password );
         userpwd->setContentWidgetData(QString("text"),settingdatalist[5]);                
         QStringList yesnoList;
-        yesnoList <<hbTrId("txt_device_update_button_yes");
-        yesnoList<<hbTrId("txt_device_update_button_no");
+        yesnoList <<hbTrId("txt_deviceupdate_setlabel_network_auth_val_yes");
+        yesnoList<<hbTrId("txt_deviceupdate_setlabel_network_auth_val_no");
         networkauth->setContentWidgetData(QString("text"), yesnoList[0]);
         networkauth->setContentWidgetData(QString("additionalText"), yesnoList[1]);        
         networkusername->setContentWidgetData(QString("text"),settingdatalist[6]);
@@ -144,7 +144,7 @@
     QString netauthdata =
             sessionmode->contentWidgetData(QString("text")).toString();
     bool netauthval = false;
-    if (netauthdata.compare("yes"))
+    if (netauthdata.compare(hbTrId("txt_deviceupdate_setlabel_network_auth_val_yes")))
         netauthval = true;
     //check server name , server id, host addr & usrname        
     if ((itemlist[0].length() > 0) && (itemlist[1].length() > 0)
@@ -258,13 +258,13 @@
         itemname = hbTrId("txt_device_update_formlabel_password");
         userpwd = dataformmodel->appendDataFormItem(HbDataFormModelItem::TextItem, itemname);
         
-        itemname = hbTrId("txt_device_update_setlabel_network_authentication");
+        itemname = hbTrId("txt_device_update_formlabel_network_authentication");
         networkauth = dataformmodel->appendDataFormItem(HbDataFormModelItem::ToggleValueItem, itemname);
         
-        itemname = hbTrId("txt_device_update_formlabel_network_user_name");
+        itemname = hbTrId("txt_device_update_formlabel_network_username");
         networkusername = dataformmodel->appendDataFormItem(HbDataFormModelItem::TextItem, itemname);
         
-        itemname = hbTrId("txt_device_update_formlabel_network_password");
+        itemname = hbTrId("txt_device_update_setlabel_network_password");
         networkpwd = dataformmodel->appendDataFormItem(HbDataFormModelItem::TextItem, itemname);
         }
     }