added gtk_dialog_help_disable(), modified gtk_dialog_help_enable() (fixes #19468)
[hildon] / hildon-widgets / hildon-grid.c
index c474da2..9ce4e20 100644 (file)
@@ -284,7 +284,7 @@ static void hildon_grid_class_init(HildonGridClass * klass)
         g_param_spec_string("empty_label",
                             "Empty label",
                             "Label to show when grid has no items",
-                            "", G_PARAM_READWRITE));
+                            _("Ckct_wi_grid_no_items"), G_PARAM_READWRITE));
 
     gtk_widget_class_install_style_property(widget_class,
         g_param_spec_uint("item_width",
@@ -441,7 +441,7 @@ hildon_grid_set_num_columns(HildonGrid * grid, gint columns)
         priv->num_columns = DEFAULT_N_COLUMNS;
     
     /* Update estimated row-count for jump_scrollbar... */
-    priv->area_rows = priv->area_height / priv->num_columns;
+    priv->area_rows = MAX(priv->area_height / priv->num_columns, 1);
 
     /* Size could have changed. Scroll view so there's something to show. */
     adjust_scrollbar_height(grid);
@@ -632,7 +632,7 @@ static void hildon_grid_init(HildonGrid * grid)
     priv->focus_index = -1;
 
     priv->scrollbar = gtk_vscrollbar_new(NULL);
-    priv->empty_label = gtk_label_new("");
+    priv->empty_label = gtk_label_new(_("Ckct_wi_grid_no_items"));
     priv->style = NULL;
 
     priv->area_height = 1;