summaryrefslogtreecommitdiff
path: root/src/caja-spatial-window.c
diff options
context:
space:
mode:
authorWu Xiaotian <[email protected]>2019-01-26 12:35:44 +0800
committerlukefromdc <[email protected]>2019-01-31 19:37:54 +0000
commite99050ad48b89cb8e1a5eaafbb9fdf2ffd418485 (patch)
tree42ebc76b8668815a60a946ad2b9b4cc6b30c9e51 /src/caja-spatial-window.c
parent7920f9788dc8a142472c358d693bb7532c46b609 (diff)
downloadcaja-e99050ad48b89cb8e1a5eaafbb9fdf2ffd418485.tar.bz2
caja-e99050ad48b89cb8e1a5eaafbb9fdf2ffd418485.tar.xz
Avoid deprecated g_type_class_add_private under src
Changed CajaSidePane, CajaSpatialWindow, CajaViewAsAction and CajaXContentBar
Diffstat (limited to 'src/caja-spatial-window.c')
-rw-r--r--src/caja-spatial-window.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/src/caja-spatial-window.c b/src/caja-spatial-window.c
index f0f32914..ec088035 100644
--- a/src/caja-spatial-window.c
+++ b/src/caja-spatial-window.c
@@ -69,7 +69,7 @@
#define SPATIAL_ACTION_CLOSE_ALL_FOLDERS "Close All Folders"
#define MENU_PATH_SPATIAL_BOOKMARKS_PLACEHOLDER "/MenuBar/Other Menus/Places/Bookmarks Placeholder"
-struct _CajaSpatialWindowDetails
+struct _CajaSpatialWindowPrivate
{
GtkActionGroup *spatial_action_group; /* owned by ui_manager */
char *last_geometry;
@@ -88,8 +88,7 @@ static const GtkTargetEntry location_button_drag_types[] =
{ CAJA_ICON_DND_URI_LIST_TYPE, 0, CAJA_ICON_DND_URI_LIST },
};
-G_DEFINE_TYPE(CajaSpatialWindow, caja_spatial_window, CAJA_TYPE_WINDOW)
-#define parent_class caja_spatial_window_parent_class
+G_DEFINE_TYPE_WITH_PRIVATE (CajaSpatialWindow, caja_spatial_window, CAJA_TYPE_WINDOW)
static void caja_spatial_window_save_geometry (CajaSpatialWindow *window,
CajaFile *viewed_file);
@@ -987,9 +986,7 @@ caja_spatial_window_init (CajaSpatialWindow *window)
CajaWindow *win;
CajaWindowPane *pane;
- window->details = G_TYPE_INSTANCE_GET_PRIVATE (window,
- CAJA_TYPE_SPATIAL_WINDOW,
- CajaSpatialWindowDetails);
+ window->details = caja_spatial_window_get_instance_private (window);
win = CAJA_WINDOW (window);
@@ -1124,6 +1121,4 @@ caja_spatial_window_class_init (CajaSpatialWindowClass *klass)
gtk_binding_entry_add_signal (binding_set, GDK_KEY_Up, GDK_SHIFT_MASK | GDK_MOD1_MASK,
"go_up", 1,
G_TYPE_BOOLEAN, TRUE);
-
- g_type_class_add_private (klass, sizeof(CajaSpatialWindowDetails));
}