Mailinglist Archive: yast-commit (190 mails)
| < Previous | Next > |
[yast-commit] r38089 - /trunk/autoinstallation/src/dialogs/general_dialogs.ycp
- From: ug@xxxxxxxxxxxxxxxx
- Date: Tue, 22 May 2007 14:29:37 -0000
- Message-id: <20070522142937.CA2BD4801F@xxxxxxxxxxxxxxxx>
Author: ug
Date: Tue May 22 16:29:37 2007
New Revision: 38089
URL: http://svn.opensuse.org/viewcvs/yast?rev=38089&view=rev
Log:
ask-UI enhancements
Modified:
trunk/autoinstallation/src/dialogs/general_dialogs.ycp
Modified: trunk/autoinstallation/src/dialogs/general_dialogs.ycp
URL: http://svn.opensuse.org/viewcvs/yast/trunk/autoinstallation/src/dialogs/general_dialogs.ycp?rev=38089&r1=38088&r2=38089&view=diff
==============================================================================
--- trunk/autoinstallation/src/dialogs/general_dialogs.ycp (original)
+++ trunk/autoinstallation/src/dialogs/general_dialogs.ycp Tue May 22 16:29:37 2007
@@ -155,8 +155,8 @@
)
),
`HBox(
- `TextEntry( `id(`selLabel), "Label", "" ),
- `TextEntry( `id(`selValue), _("Value"), "" ),
+ `TextEntry( `id(`selLabel), `opt(`notify,`immediate), "Label", "" ),
+ `TextEntry( `id(`selValue), `opt(`notify,`immediate), _("Value"), "" ),
`PushButton( `id( `addSelection ), `opt( `default, `hstretch ), _("Add") )
),
`HBox(
@@ -168,6 +168,17 @@
string help_text = _("<P></P>");
UI::OpenDialog( `opt(`decorated ), contents );
repeat {
+ if( size( (list)UI::QueryWidget(`id(`selection), `Items) ) == 0 ) {
+ UI::ChangeWidget(`id(`delSelection) , `Enabled, false);
+ } else {
+ UI::ChangeWidget(`id(`delSelection) , `Enabled, true);
+ }
+ if( size( (string)UI::QueryWidget(`id(`selLabel), `Value) ) == 0 ||
+ size( (string)UI::QueryWidget(`id(`selValue), `Value) ) == 0 ) {
+ UI::ChangeWidget(`id(`addSelection) , `Enabled, false);
+ } else {
+ UI::ChangeWidget(`id(`addSelection) , `Enabled, true);
+ }
ret = (symbol)UI::UserInput();
if( ret == `addSelection ) {
string label = (string)UI::QueryWidget(`id(`selLabel), `Value);
@@ -194,7 +205,8 @@
"title":title,
"stage":stage,
"dialog":dialog,
- "element":defaultValues["element"]:max,
+ "element":defaultValues["element"]:max,
+ "script":defaultValues["script"]:"",
"question":(string)UI::QueryWidget(`id(`question), `Value) ];
if( (string)UI::QueryWidget(`id(`frametitle), `Value) != "" )
newVal["frametitle"] = (string)UI::QueryWidget(`id(`frametitle), `Value);
--
To unsubscribe, e-mail: yast-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: yast-commit+help@xxxxxxxxxxxx
Date: Tue May 22 16:29:37 2007
New Revision: 38089
URL: http://svn.opensuse.org/viewcvs/yast?rev=38089&view=rev
Log:
ask-UI enhancements
Modified:
trunk/autoinstallation/src/dialogs/general_dialogs.ycp
Modified: trunk/autoinstallation/src/dialogs/general_dialogs.ycp
URL: http://svn.opensuse.org/viewcvs/yast/trunk/autoinstallation/src/dialogs/general_dialogs.ycp?rev=38089&r1=38088&r2=38089&view=diff
==============================================================================
--- trunk/autoinstallation/src/dialogs/general_dialogs.ycp (original)
+++ trunk/autoinstallation/src/dialogs/general_dialogs.ycp Tue May 22 16:29:37 2007
@@ -155,8 +155,8 @@
)
),
`HBox(
- `TextEntry( `id(`selLabel), "Label", "" ),
- `TextEntry( `id(`selValue), _("Value"), "" ),
+ `TextEntry( `id(`selLabel), `opt(`notify,`immediate), "Label", "" ),
+ `TextEntry( `id(`selValue), `opt(`notify,`immediate), _("Value"), "" ),
`PushButton( `id( `addSelection ), `opt( `default, `hstretch ), _("Add") )
),
`HBox(
@@ -168,6 +168,17 @@
string help_text = _("<P></P>");
UI::OpenDialog( `opt(`decorated ), contents );
repeat {
+ if( size( (list)UI::QueryWidget(`id(`selection), `Items) ) == 0 ) {
+ UI::ChangeWidget(`id(`delSelection) , `Enabled, false);
+ } else {
+ UI::ChangeWidget(`id(`delSelection) , `Enabled, true);
+ }
+ if( size( (string)UI::QueryWidget(`id(`selLabel), `Value) ) == 0 ||
+ size( (string)UI::QueryWidget(`id(`selValue), `Value) ) == 0 ) {
+ UI::ChangeWidget(`id(`addSelection) , `Enabled, false);
+ } else {
+ UI::ChangeWidget(`id(`addSelection) , `Enabled, true);
+ }
ret = (symbol)UI::UserInput();
if( ret == `addSelection ) {
string label = (string)UI::QueryWidget(`id(`selLabel), `Value);
@@ -194,7 +205,8 @@
"title":title,
"stage":stage,
"dialog":dialog,
- "element":defaultValues["element"]:max,
+ "element":defaultValues["element"]:max,
+ "script":defaultValues["script"]:"",
"question":(string)UI::QueryWidget(`id(`question), `Value) ];
if( (string)UI::QueryWidget(`id(`frametitle), `Value) != "" )
newVal["frametitle"] = (string)UI::QueryWidget(`id(`frametitle), `Value);
--
To unsubscribe, e-mail: yast-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: yast-commit+help@xxxxxxxxxxxx
| < Previous | Next > |