Mailinglist Archive: yast-commit (953 mails)

< Previous Next >
[yast-commit] r49601 - in /trunk/gtk: ChangeLog src/YGRadioButton.cc
  • From: rpmcruz@xxxxxxxxxxxxxxxx
  • Date: Sun, 03 Aug 2008 02:31:40 -0000
  • Message-id: <20080803023140.E5FB529689@xxxxxxxxxxxxxxxx>
Author: rpmcruz
Date: Sun Aug 3 04:31:40 2008
New Revision: 49601

URL: http://svn.opensuse.org/viewcvs/yast?rev=49601&view=rev
Log:
* src/YGRadioButton.cc: we set radio and check buttons horizontally
stretchable
to fill all the area, for cosmetic reasons. Don't do it when inside an
horizontal
box as it messes the layout.

Modified:
trunk/gtk/ChangeLog
trunk/gtk/src/YGRadioButton.cc

Modified: trunk/gtk/ChangeLog
URL:
http://svn.opensuse.org/viewcvs/yast/trunk/gtk/ChangeLog?rev=49601&r1=49600&r2=49601&view=diff
==============================================================================
--- trunk/gtk/ChangeLog (original)
+++ trunk/gtk/ChangeLog Sun Aug 3 04:31:40 2008
@@ -12,6 +12,10 @@
* src/YGTable.cc: looks like yast2-qt sends two signals when a combo box
item is selected. Replicate the behavior as the printer tool depends on
it.

+ * src/YGRadioButton.cc: we set radio and check buttons horizontally
stretchable
+ to fill all the area, for cosmetic reasons. Don't do it when inside an
horizontal
+ box as it messes the layout.
+
2008-07-31 Ricardo Cruz <rpmcruz@xxxxxxxxxxxxxxxxxxx>

* src/YGPackageSelector.cc: online update was broken.

Modified: trunk/gtk/src/YGRadioButton.cc
URL:
http://svn.opensuse.org/viewcvs/yast/trunk/gtk/src/YGRadioButton.cc?rev=49601&r1=49600&r2=49601&view=diff
==============================================================================
--- trunk/gtk/src/YGRadioButton.cc (original)
+++ trunk/gtk/src/YGRadioButton.cc Sun Aug 3 04:31:40 2008
@@ -31,6 +31,16 @@
return type;
}

+#include "YLayoutBox.h"
+
+static bool is_horizontal_box (YWidget *widget)
+{
+ YLayoutBox *box = dynamic_cast <YLayoutBox *> (widget);
+ if (box)
+ return box->primary() == YD_HORIZ;
+ return false;
+}
+
#include "YRadioButton.h"
#include "YRadioButtonGroup.h"

@@ -43,7 +53,8 @@
{
IMPL
setBorder (0);
- setStretchable (YD_HORIZ, true);
+ if (!is_horizontal_box (parent))
+ setStretchable (YD_HORIZ, true);
setLabel (label);
gtk_button_set_use_underline (GTK_BUTTON (getWidget()), TRUE);
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (getWidget()),
FALSE);
@@ -141,7 +152,8 @@
{
IMPL
setBorder (0);
- setStretchable (YD_HORIZ, true);
+ if (!is_horizontal_box (parent))
+ setStretchable (YD_HORIZ, true);
setLabel (label);
gtk_button_set_use_underline (GTK_BUTTON (getWidget()), TRUE);
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (getWidget()),
isChecked);

--
To unsubscribe, e-mail: yast-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: yast-commit+help@xxxxxxxxxxxx

< Previous Next >
This Thread
  • No further messages