@@ -117,7 +117,6 @@ static struct win_position get_window_position(uint32_t, struct client *);
117
117
static bool is_overlapping (struct client * , struct client * );
118
118
static bool is_in_valid_direction (uint32_t , float , float );
119
119
static bool is_in_cardinal_direction (uint32_t , struct client * , struct client * );
120
- static void save_original_size (struct client * );
121
120
static xcb_atom_t get_atom (char * );
122
121
static void update_desktop_viewport (void );
123
122
static bool get_pointer_location (xcb_window_t * , int16_t * , int16_t * );
@@ -1077,7 +1076,7 @@ maximize_window(struct client *client, int16_t mon_x, int16_t mon_y, uint16_t mo
1077
1076
/* maximized windows don't have borders */
1078
1077
values [0 ] = 0 ;
1079
1078
if (client -> geom .width != mon_width || client -> geom .height != mon_height )
1080
- save_original_size ( client ) ;
1079
+ client -> orig_geom = client -> geom ;
1081
1080
xcb_configure_window (conn , client -> window , XCB_CONFIG_WINDOW_BORDER_WIDTH ,
1082
1081
values );
1083
1082
@@ -1104,7 +1103,7 @@ hmaximize_window(struct client *client, int16_t mon_x, uint16_t mon_width)
1104
1103
unmaximize_window (client );
1105
1104
1106
1105
if (client -> geom .width != mon_width )
1107
- save_original_size ( client ) ;
1106
+ client -> orig_geom = client -> geom ;
1108
1107
client -> geom .x = mon_x + conf .gap_left ;
1109
1108
client -> geom .width = mon_width - conf .gap_left - conf .gap_right - 2 * conf .border_width ;
1110
1109
@@ -1126,7 +1125,7 @@ vmaximize_window(struct client *client, int16_t mon_y, uint16_t mon_height)
1126
1125
unmaximize_window (client );
1127
1126
1128
1127
if (client -> geom .height != mon_height )
1129
- save_original_size ( client ) ;
1128
+ client -> orig_geom = client -> geom ;
1130
1129
1131
1130
client -> geom .y = mon_y + conf .gap_up ;
1132
1131
client -> geom .height = mon_height - conf .gap_up - conf .gap_down - 2 * conf .border_width ;
@@ -1148,7 +1147,7 @@ monocle_window(struct client *client, int16_t mon_x, int16_t mon_y, uint16_t mon
1148
1147
if (is_maxed (client ))
1149
1148
unmaximize_window (client );
1150
1149
1151
- save_original_size ( client ) ;
1150
+ client -> orig_geom = client -> geom ;
1152
1151
1153
1152
client -> geom .x = mon_x + conf .gap_left ;
1154
1153
client -> geom .y = mon_y + conf .gap_up ;
@@ -1565,15 +1564,6 @@ get_distance_between_windows(struct client *a, struct client *b)
1565
1564
return distance ;
1566
1565
}
1567
1566
1568
- static void
1569
- save_original_size (struct client * client )
1570
- {
1571
- client -> orig_geom .x = client -> geom .x ;
1572
- client -> orig_geom .y = client -> geom .y ;
1573
- client -> orig_geom .width = client -> geom .width ;
1574
- client -> orig_geom .height = client -> geom .height ;
1575
- }
1576
-
1577
1567
/*
1578
1568
* Get atom by name.
1579
1569
*/
0 commit comments