summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLibravatar wil <william.barsse@gmail.com>2017-01-08 18:08:10 +0100
committerLibravatar wil <william.barsse@gmail.com>2017-01-08 18:08:10 +0100
commit52f3a8df511ca52079011db84aaf53464b81c562 (patch)
tree6153d8178ec4c732356ab3ed13888b2f267713ee
parentreworked "layout auto*" star commands (diff)
downloadsway-52f3a8df511ca52079011db84aaf53464b81c562.tar.gz
sway-52f3a8df511ca52079011db84aaf53464b81c562.tar.zst
sway-52f3a8df511ca52079011db84aaf53464b81c562.zip
fixed up space-after-cast style issues
-rw-r--r--sway/layout.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/sway/layout.c b/sway/layout.c
index 869a3bcb..fdd2fe6b 100644
--- a/sway/layout.c
+++ b/sway/layout.c
@@ -322,14 +322,14 @@ void move_container(swayc_t *container, enum movement_direction dir) {
322 // if move command makes container change from master to slave 322 // if move command makes container change from master to slave
323 // (or the contrary), reset its geometry an the one of the replaced item. 323 // (or the contrary), reset its geometry an the one of the replaced item.
324 if (parent->nb_master 324 if (parent->nb_master
325 && (size_t) parent->children->length > parent->nb_master) { 325 && (size_t)parent->children->length > parent->nb_master) {
326 swayc_t *swap_geom = NULL; 326 swayc_t *swap_geom = NULL;
327 // if child is being promoted/demoted, it will swap geometry 327 // if child is being promoted/demoted, it will swap geometry
328 // with the sibling being demoted/promoted. 328 // with the sibling being demoted/promoted.
329 if ((dir == MOVE_NEXT && desired == 0) 329 if ((dir == MOVE_NEXT && desired == 0)
330 || (dir == MOVE_PREV && (size_t) desired == parent->nb_master - 1)) { 330 || (dir == MOVE_PREV && (size_t)desired == parent->nb_master - 1)) {
331 swap_geom = parent->children->items[parent->nb_master - 1]; 331 swap_geom = parent->children->items[parent->nb_master - 1];
332 } else if ((dir == MOVE_NEXT && (size_t) desired == parent->nb_master) 332 } else if ((dir == MOVE_NEXT && (size_t)desired == parent->nb_master)
333 || (dir == MOVE_PREV && desired == parent->children->length - 1)) { 333 || (dir == MOVE_PREV && desired == parent->children->length - 1)) {
334 swap_geom = parent->children->items[parent->nb_master]; 334 swap_geom = parent->children->items[parent->nb_master];
335 } 335 }
@@ -1537,7 +1537,7 @@ size_t auto_group_count(const swayc_t *container) {
1537 */ 1537 */
1538int auto_group_start_index(const swayc_t *container, int index) { 1538int auto_group_start_index(const swayc_t *container, int index) {
1539 if (index < 0 || ! is_auto_layout(container->layout) 1539 if (index < 0 || ! is_auto_layout(container->layout)
1540 || (size_t) index < container->nb_master) { 1540 || (size_t)index < container->nb_master) {
1541 return 0; 1541 return 0;
1542 } else { 1542 } else {
1543 size_t nb_slaves = auto_slave_count(container); 1543 size_t nb_slaves = auto_slave_count(container);
@@ -1593,7 +1593,7 @@ size_t auto_group_index(const swayc_t *container, int index) {
1593 } 1593 }
1594 bool master_first = (container->layout == L_AUTO_LEFT || container->layout == L_AUTO_TOP); 1594 bool master_first = (container->layout == L_AUTO_LEFT || container->layout == L_AUTO_TOP);
1595 size_t nb_slaves = auto_slave_count(container); 1595 size_t nb_slaves = auto_slave_count(container);
1596 if ((size_t) index < container->nb_master) { 1596 if ((size_t)index < container->nb_master) {
1597 if (master_first || nb_slaves <= 0) { 1597 if (master_first || nb_slaves <= 0) {
1598 return 0; 1598 return 0;
1599 } else { 1599 } else {