author | wimpie <wimpie> | 2005-01-12 01:55:32 (UTC) |
---|---|---|
committer | wimpie <wimpie> | 2005-01-12 01:55:32 (UTC) |
commit | c48160f6ac67b2f2fc4b6f982b641861ad078237 (patch) (unidiff) | |
tree | 2922ac7b627091ef32f36d4e8b32630c255b00e1 /noncore/settings/networksettings2/profile | |
parent | f9a83585111afa08a47176097a150d9f468bfcdf (diff) | |
download | opie-c48160f6ac67b2f2fc4b6f982b641861ad078237.zip opie-c48160f6ac67b2f2fc4b6f982b641861ad078237.tar.gz opie-c48160f6ac67b2f2fc4b6f982b641861ad078237.tar.bz2 |
Fixed problem with enabling profile from edit environment
rename disable to enable (much more clear)
Diffstat (limited to 'noncore/settings/networksettings2/profile') (more/less context) (ignore whitespace changes)
5 files changed, 21 insertions, 19 deletions
diff --git a/noncore/settings/networksettings2/profile/profileGUI.ui b/noncore/settings/networksettings2/profile/profileGUI.ui index 8b421e8..eeb2e75 100644 --- a/noncore/settings/networksettings2/profile/profileGUI.ui +++ b/noncore/settings/networksettings2/profile/profileGUI.ui | |||
@@ -13,3 +13,3 @@ | |||
13 | <y>0</y> | 13 | <y>0</y> |
14 | <width>551</width> | 14 | <width>547</width> |
15 | <height>547</height> | 15 | <height>547</height> |
@@ -134,3 +134,3 @@ | |||
134 | <name>name</name> | 134 | <name>name</name> |
135 | <cstring>Disabled_CB</cstring> | 135 | <cstring>Enabled_CB</cstring> |
136 | </property> | 136 | </property> |
@@ -142,3 +142,3 @@ | |||
142 | <name>text</name> | 142 | <name>text</name> |
143 | <string>Disabled</string> | 143 | <string>Enabled</string> |
144 | </property> | 144 | </property> |
diff --git a/noncore/settings/networksettings2/profile/profile_NNI.cpp b/noncore/settings/networksettings2/profile/profile_NNI.cpp index fc2d809..0bc13d1 100644 --- a/noncore/settings/networksettings2/profile/profile_NNI.cpp +++ b/noncore/settings/networksettings2/profile/profile_NNI.cpp | |||
@@ -10,3 +10,3 @@ AProfile::AProfile( ProfileNetNode * PNN ) : ANetNodeInstance( PNN ) { | |||
10 | Data.Description = ""; | 10 | Data.Description = ""; |
11 | Data.Disabled = 0; | 11 | Data.Enabled = 1; |
12 | Data.TriggerVPN = 0; | 12 | Data.TriggerVPN = 0; |
@@ -23,3 +23,5 @@ void AProfile::setSpecificAttribute( QString & Attr, QString & Value ) { | |||
23 | } else if ( Attr == "disabled" ) { | 23 | } else if ( Attr == "disabled" ) { |
24 | Data.Disabled = (Value=="yes"); | 24 | Data.Enabled = (Value=="no"); |
25 | } else if ( Attr == "enabled" ) { | ||
26 | Data.Enabled = (Value=="yes"); | ||
25 | } else if ( Attr == "triggervpn" ) { | 27 | } else if ( Attr == "triggervpn" ) { |
@@ -34,3 +36,3 @@ void AProfile::saveSpecificAttribute( QTextStream & TS ) { | |||
34 | TS << "preconfirm=" << ((Data.Confirm) ? "yes" : "no") << endl; | 36 | TS << "preconfirm=" << ((Data.Confirm) ? "yes" : "no") << endl; |
35 | TS << "disabled=" << ((Data.Disabled) ? "yes" : "no") << endl; | 37 | TS << "enabled=" << ((Data.Enabled) ? "yes" : "no") << endl; |
36 | TS << "triggervpn=" << ((Data.TriggerVPN) ? "yes" : "no") << endl; | 38 | TS << "triggervpn=" << ((Data.TriggerVPN) ? "yes" : "no") << endl; |
diff --git a/noncore/settings/networksettings2/profile/profiledata.h b/noncore/settings/networksettings2/profile/profiledata.h index 2f7060d..376b393 100644 --- a/noncore/settings/networksettings2/profile/profiledata.h +++ b/noncore/settings/networksettings2/profile/profiledata.h | |||
@@ -11,4 +11,4 @@ public : | |||
11 | bool Confirm; | 11 | bool Confirm; |
12 | // Do not bring this networkSetup up | 12 | // bring this networkSetup up |
13 | bool Disabled; | 13 | bool Enabled; |
14 | bool TriggerVPN; | 14 | bool TriggerVPN; |
diff --git a/noncore/settings/networksettings2/profile/profileedit.cpp b/noncore/settings/networksettings2/profile/profileedit.cpp index 1713f0c..818bad6 100644 --- a/noncore/settings/networksettings2/profile/profileedit.cpp +++ b/noncore/settings/networksettings2/profile/profileedit.cpp | |||
@@ -72,3 +72,3 @@ void ProfileEdit::showData( ProfileData & Data ) { | |||
72 | Confirm_CB->setChecked( Data.Confirm ); | 72 | Confirm_CB->setChecked( Data.Confirm ); |
73 | Disabled_CB->setChecked( Data.Disabled ); | 73 | Enabled_CB->setChecked( Data.Enabled ); |
74 | } | 74 | } |
@@ -82,3 +82,3 @@ bool ProfileEdit::commit( ProfileData & Data ) { | |||
82 | CBM( Data.TriggerVPN, TriggersVPN_CB, SM ); | 82 | CBM( Data.TriggerVPN, TriggersVPN_CB, SM ); |
83 | CBM( Data.Disabled, Disabled_CB, SM ); | 83 | CBM( Data.Enabled, Enabled_CB, SM ); |
84 | CBM( Data.Confirm, Confirm_CB, SM ); | 84 | CBM( Data.Confirm, Confirm_CB, SM ); |
diff --git a/noncore/settings/networksettings2/profile/profilerun.cpp b/noncore/settings/networksettings2/profile/profilerun.cpp index 77bf9ac..faa7d66 100644 --- a/noncore/settings/networksettings2/profile/profilerun.cpp +++ b/noncore/settings/networksettings2/profile/profilerun.cpp | |||
@@ -6,8 +6,8 @@ State_t ProfileRun::detectState( void ) { | |||
6 | 6 | ||
7 | Log(( "Profile %sabled\n", (Data->Disabled) ? "dis" : "en" )); | 7 | Log(( "Profile %sabled\n", (Data->Enabled) ? "en" : "dis" )); |
8 | 8 | ||
9 | if( Data->Disabled ) { | 9 | if( Data->Enabled ) { |
10 | return Disabled; | 10 | return Unknown; |
11 | } | 11 | } |
12 | return Unknown; | 12 | return Disabled; |
13 | } | 13 | } |
@@ -15,6 +15,6 @@ State_t ProfileRun::detectState( void ) { | |||
15 | QString ProfileRun::setMyState( NetworkSetup * NC, Action_t A, bool ) { | 15 | QString ProfileRun::setMyState( NetworkSetup * NC, Action_t A, bool ) { |
16 | odebug << "Profile " << Data->Disabled << oendl; | 16 | odebug << "Profile " << Data->Enabled << oendl; |
17 | if( A == Disable ) { | 17 | if( A == Disable ) { |
18 | if( ! Data->Disabled ) { | 18 | if( Data->Enabled ) { |
19 | Data->Disabled = 1; | 19 | Data->Enabled = 0; |
20 | NC->setModified( 1 ); | 20 | NC->setModified( 1 ); |
@@ -22,4 +22,4 @@ QString ProfileRun::setMyState( NetworkSetup * NC, Action_t A, bool ) { | |||
22 | } else if( A == Enable ) { | 22 | } else if( A == Enable ) { |
23 | if( Data->Disabled ) { | 23 | if( ! Data->Enabled ) { |
24 | Data->Disabled = 0; | 24 | Data->Enabled = 1; |
25 | NC->setModified( 1 ); | 25 | NC->setModified( 1 ); |