diff options
author | Martin Wimpress <[email protected]> | 2015-06-15 20:08:18 +0100 |
---|---|---|
committer | Martin Wimpress <[email protected]> | 2015-06-15 20:08:18 +0100 |
commit | 232a6c95d121fb92c372476a29fabf4846446143 (patch) | |
tree | a9cc643e8276a441d4fcd379ae0e288d515c0d66 /src/eom-thumb-nav.c | |
parent | 77d3fe8eb9c69de333a53e54c681d27eff6ec223 (diff) | |
parent | 16ecee965b67eaf37e52c745f6369f49377e86b2 (diff) | |
download | eom-232a6c95d121fb92c372476a29fabf4846446143.tar.bz2 eom-232a6c95d121fb92c372476a29fabf4846446143.tar.xz |
Merge pull request #81 from NiceandGently/dev-thumbview
GTK3: fix broken thumbview
Diffstat (limited to 'src/eom-thumb-nav.c')
-rw-r--r-- | src/eom-thumb-nav.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/eom-thumb-nav.c b/src/eom-thumb-nav.c index 702b4c5..24c2431 100644 --- a/src/eom-thumb-nav.c +++ b/src/eom-thumb-nav.c @@ -545,8 +545,13 @@ eom_thumb_nav_set_mode (EomThumbNav *nav, EomThumbNavMode mode) switch (mode) { case EOM_THUMB_NAV_MODE_ONE_ROW: +#if GTK_CHECK_VERSION (3, 4, 3) + gtk_orientable_set_orientation (GTK_ORIENTABLE(priv->thumbview), + GTK_ORIENTATION_HORIZONTAL); +#else gtk_icon_view_set_columns (GTK_ICON_VIEW (priv->thumbview), G_MAXINT); +#endif gtk_widget_set_size_request (priv->thumbview, -1, -1); eom_thumb_view_set_item_height (EOM_THUMB_VIEW (priv->thumbview), @@ -561,7 +566,12 @@ eom_thumb_nav_set_mode (EomThumbNav *nav, EomThumbNavMode mode) break; case EOM_THUMB_NAV_MODE_ONE_COLUMN: +#if GTK_CHECK_VERSION (3, 4, 3) + gtk_orientable_set_orientation (GTK_ORIENTABLE(priv->thumbview), + GTK_ORIENTATION_VERTICAL); +#else gtk_icon_view_set_columns (GTK_ICON_VIEW (priv->thumbview), 1); +#endif gtk_widget_set_size_request (priv->thumbview, -1, -1); eom_thumb_view_set_item_height (EOM_THUMB_VIEW (priv->thumbview), @@ -577,7 +587,12 @@ eom_thumb_nav_set_mode (EomThumbNav *nav, EomThumbNavMode mode) break; case EOM_THUMB_NAV_MODE_MULTIPLE_ROWS: +#if GTK_CHECK_VERSION (3, 4, 3) + gtk_orientable_set_orientation (GTK_ORIENTABLE(priv->thumbview), + GTK_ORIENTATION_VERTICAL); +#else gtk_icon_view_set_columns (GTK_ICON_VIEW (priv->thumbview), -1); +#endif gtk_widget_set_size_request (priv->thumbview, -1, 220); eom_thumb_view_set_item_height (EOM_THUMB_VIEW (priv->thumbview), @@ -593,7 +608,12 @@ eom_thumb_nav_set_mode (EomThumbNav *nav, EomThumbNavMode mode) break; case EOM_THUMB_NAV_MODE_MULTIPLE_COLUMNS: +#if GTK_CHECK_VERSION (3, 4, 3) + gtk_orientable_set_orientation (GTK_ORIENTABLE(priv->thumbview), + GTK_ORIENTATION_VERTICAL); +#else gtk_icon_view_set_columns (GTK_ICON_VIEW (priv->thumbview), -1); +#endif gtk_widget_set_size_request (priv->thumbview, 230, -1); eom_thumb_view_set_item_height (EOM_THUMB_VIEW (priv->thumbview), |