Author: locilka Date: Fri Sep 9 15:58:01 2011 New Revision: 65640 URL: http://svn.opensuse.org/viewcvs/yast?rev=65640&view=rev Log: - Using ButtonBox in Wizard where possible (bnc#571939) Modified: trunk/yast2/library/wizard/src/Wizard.ycp trunk/yast2/package/yast2.changes Modified: trunk/yast2/library/wizard/src/Wizard.ycp URL: http://svn.opensuse.org/viewcvs/yast/trunk/yast2/library/wizard/src/Wizard.ycp?rev=65640&r1=65639&r2=65640&view=diff ============================================================================== --- trunk/yast2/library/wizard/src/Wizard.ycp (original) +++ trunk/yast2/library/wizard/src/Wizard.ycp Fri Sep 9 15:58:01 2011 @@ -106,14 +106,10 @@ **/ global term CancelAcceptButtonBox() { - return `HBox( - `HWeight(1, `Empty() ), // Layout trick to make sure the center button is centered - `HStretch(), - `HWeight(1, `ReplacePoint(`id(`rep_abort), // Make sure HideAbortButton() works (bnc #444176) - `PushButton(`id(`cancel ), `opt (`key_F9), Label::CancelButton() ) ) ), - `HStretch(), - `HWeight(1, `PushButton(`id(`accept ), `opt (`key_F10, `default), Label::AcceptButton() ) ) - ); + return `ButtonBox ( + `PushButton(`id(`cancel), `opt (`key_F9, `cancelButton), Label::CancelButton()), + `PushButton(`id(`accept), `opt (`key_F10, `default, `okButton), Label::AcceptButton()) + ); } @@ -123,14 +119,10 @@ **/ global term CancelOKButtonBox() { - return `HBox( - `HWeight(1, `Empty() ), // Layout trick to make sure the center button is centered - `HStretch(), - `HWeight(1, `ReplacePoint(`id(`rep_abort), // Make sure HideAbortButton() works (bnc #444176) - `PushButton(`id(`cancel ), `opt (`key_F9), Label::CancelButton() ) ) ), - `HStretch(), - `HWeight(1, `PushButton(`id(`ok ), `opt (`key_F10, `default), Label::OKButton() ) ) - ); + return `ButtonBox ( + `PushButton(`id(`cancel), `opt(`key_F9, `cancelButton), Label::CancelButton()), + `PushButton(`id(`ok), `opt(`key_F10, `default, `okButton), Label::OKButton()) + ); } @@ -157,13 +149,10 @@ **/ global term AbortInstallationAcceptButtonBox() { - return `HBox( - `HWeight(1, `Empty() ), // Layout trick to make sure the center button is centered - `HStretch(), - `PushButton(`id(`abort ), `opt (`key_F9), Label::AbortInstallationButton() ), - `HStretch(), - `HWeight(1, `PushButton(`id(`accept ), `opt (`key_F10, `default), Label::AcceptButton() ) ) - ); + return `ButtonBox ( + `PushButton(`id(`abort), `opt (`key_F9, `cancelButton), Label::AbortInstallationButton()), + `PushButton(`id(`accept), `opt (`key_F10, `okButton, `default), Label::AcceptButton()) + ); } @@ -951,6 +940,8 @@ { if ( UI::WidgetExists(`id(`rep_abort ) ) ) UI::ReplaceWidget(`id(`rep_abort ), `Empty() ); + else if ( UI::WidgetExists(`id(`cancel ) ) ) + UI::ReplaceWidget(`id(`cancel ), `Empty() ); } } Modified: trunk/yast2/package/yast2.changes URL: http://svn.opensuse.org/viewcvs/yast/trunk/yast2/package/yast2.changes?rev=65640&r1=65639&r2=65640&view=diff ============================================================================== --- trunk/yast2/package/yast2.changes (original) +++ trunk/yast2/package/yast2.changes Fri Sep 9 15:58:01 2011 @@ -1,4 +1,9 @@ ------------------------------------------------------------------- +Fri Sep 9 15:56:48 CEST 2011 - locilka@suse.cz + +- Using ButtonBox in Wizard where possible (bnc#571939) + +------------------------------------------------------------------- Thu Sep 8 16:13:26 UTC 2011 - lslezak@suse.cz - adapted to systemd (bnc#664548) -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org