Author: rpmcruz
Date: Fri Jan 29 13:17:42 2010
New Revision: 60615
URL: http://svn.opensuse.org/viewcvs/yast?rev=60615&view=rev
Log:
* src/YGTable.cc: bug fix 567505: crash when cell is
unset: see firewall tool.
* src/YGUI.cc: bug fix 547261: work around broken metacity
icon by defaulting to the generic yast2 icon.
Modified:
trunk/gtk/ChangeLog
trunk/gtk/src/YGTable.cc
trunk/gtk/src/YGUI.cc
Modified: trunk/gtk/ChangeLog
URL: http://svn.opensuse.org/viewcvs/yast/trunk/gtk/ChangeLog?rev=60615&r1=60614&r2=60615&view=diff
==============================================================================
--- trunk/gtk/ChangeLog (original)
+++ trunk/gtk/ChangeLog Fri Jan 29 13:17:42 2010
@@ -1,3 +1,11 @@
+2010-01-29 Ricardo Cruz
+
+ * src/YGTable.cc: bug fix 567505: crash when cell is
+ unset: see firewall tool.
+
+ * src/YGUI.cc: bug fix 547261: work around broken metacity
+ icon by defaulting to the generic yast2 icon.
+
2010-01-27 Ricardo Cruz
* src/pkg/YGPackageSelector.cc: added --embold-installed-row
Modified: trunk/gtk/src/YGTable.cc
URL: http://svn.opensuse.org/viewcvs/yast/trunk/gtk/src/YGTable.cc?rev=60615&r1=60614&r2=60615&view=diff
==============================================================================
--- trunk/gtk/src/YGTable.cc (original)
+++ trunk/gtk/src/YGTable.cc Fri Jan 29 13:17:42 2010
@@ -295,16 +295,20 @@
{
GtkTreeIter iter;
if (getIter (cell->parent(), &iter))
- setCell (&iter, cell);
+ setCell (&iter, cell->column(), cell);
}
- void setCell (GtkTreeIter *iter, const YTableCell *cell)
+ void setCell (GtkTreeIter *iter, int column, const YTableCell *cell)
{
- int index = cell->column() * 2;
- setCellIcon (iter, index, cell->iconName());
- std::string label (cell->label());
- if (label == "X")
- label = YUI::app()->glyph (YUIGlyph_CheckMark);
+ int index = column * 2;
+ std::string icon, label;
+ if (cell) {
+ icon = cell->iconName();
+ label = cell->label();
+ if (label == "X")
+ label = YUI::app()->glyph (YUIGlyph_CheckMark);
+ }
+ setCellIcon (iter, index, icon);
setCellLabel (iter, index+1, label);
}
@@ -350,7 +354,7 @@
GtkTreeIter iter;
addRow (&iter, _item, true);
for (int i = 0; i < columns(); i++)
- setCell (&iter, item->cell (i));
+ setCell (&iter, i, item->cell (i));
}
else
yuiError() << "Can only add YTableItems to a YTable.\n";
Modified: trunk/gtk/src/YGUI.cc
URL: http://svn.opensuse.org/viewcvs/yast/trunk/gtk/src/YGUI.cc?rev=60615&r1=60614&r2=60615&view=diff
==============================================================================
--- trunk/gtk/src/YGUI.cc (original)
+++ trunk/gtk/src/YGUI.cc Fri Jan 29 13:17:42 2010
@@ -153,6 +153,12 @@
g_log_set_always_fatal (GLogLevelFlags (G_LOG_LEVEL_ERROR|G_LOG_LEVEL_CRITICAL|
G_LOG_LEVEL_WARNING| G_LOG_LEVEL_MESSAGE|G_LOG_LEVEL_INFO|G_LOG_LEVEL_DEBUG));
#endif
+
+ GdkPixbuf *pixbuf = YGUtils::loadPixbuf (THEMEDIR "/icons/32x32/apps/yast.png");
+ if (pixbuf) { // default window icon
+ gtk_window_set_default_icon (pixbuf);
+ g_object_unref (G_OBJECT (pixbuf));
+ }
}
static gboolean ycp_wakeup_fn (GIOChannel *source, GIOCondition condition,
--
To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org
For additional commands, e-mail: yast-commit+help@opensuse.org