|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
From 0508a4dfb8300000fcfc5fa5147582e5feebf1a8 Mon Sep 17 00:00:00 2001
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= <zbyszek@in.waw.pl>
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
Date: Tue, 23 Sep 2014 09:22:33 -0400
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
Subject: [PATCH] terminal: fix spelling mistake
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
---
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
src/libsystemd-terminal/grdev-internal.h | 4 ++--
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
src/libsystemd-terminal/grdev.c | 28 ++++++++++++++--------------
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
2 files changed, 16 insertions(+), 16 deletions(-)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
diff --git a/src/libsystemd-terminal/grdev-internal.h b/src/libsystemd-terminal/grdev-internal.h
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
index ee182695ce..f455dd4172 100644
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
--- a/src/libsystemd-terminal/grdev-internal.h
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+++ b/src/libsystemd-terminal/grdev-internal.h
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -60,7 +60,7 @@ enum {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
};
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
struct grdev_tile {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- LIST_FIELDS(grdev_tile, childs_by_node);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ LIST_FIELDS(grdev_tile, children_by_node);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
grdev_tile *parent;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
grdev_display *display;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -79,7 +79,7 @@ struct grdev_tile {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
} leaf;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
struct {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- size_t n_childs;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ size_t n_children;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
LIST_HEAD(grdev_tile, child_list);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
} node;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
};
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
diff --git a/src/libsystemd-terminal/grdev.c b/src/libsystemd-terminal/grdev.c
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
index e34112ee7c..c5ea524c69 100644
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
--- a/src/libsystemd-terminal/grdev.c
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+++ b/src/libsystemd-terminal/grdev.c
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -54,10 +54,10 @@ static inline grdev_tile *tile_leftmost(grdev_tile *tile) {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
}
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
#define TILE_FOREACH(_root, _i) \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- for (_i = tile_leftmost(_root); _i; _i = tile_leftmost(_i->childs_by_node_next) ? : _i->parent)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ for (_i = tile_leftmost(_root); _i; _i = tile_leftmost(_i->children_by_node_next) ? : _i->parent)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
#define TILE_FOREACH_SAFE(_root, _i, _next) \
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- for (_i = tile_leftmost(_root); _i && ((_next = tile_leftmost(_i->childs_by_node_next) ? : _i->parent), true); _i = _next)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ for (_i = tile_leftmost(_root); _i && ((_next = tile_leftmost(_i->children_by_node_next) ? : _i->parent), true); _i = _next)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
static void tile_link(grdev_tile *tile, grdev_tile *parent) {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
grdev_display *display;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -73,8 +73,8 @@ static void tile_link(grdev_tile *tile, grdev_tile *parent) {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
assert(!display || !display->enabled);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- ++parent->node.n_childs;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- LIST_PREPEND(childs_by_node, parent->node.child_list, tile);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ ++parent->node.n_children;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ LIST_PREPEND(children_by_node, parent->node.child_list, tile);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
tile->parent = parent;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
if (display) {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -105,10 +105,10 @@ static void tile_unlink(grdev_tile *tile) {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
assert(parent->type == GRDEV_TILE_NODE);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
assert(parent->display == display);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- assert(parent->node.n_childs > 0);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ assert(parent->node.n_children > 0);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- --parent->node.n_childs;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- LIST_REMOVE(childs_by_node, parent->node.child_list, tile);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ --parent->node.n_children;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ LIST_REMOVE(children_by_node, parent->node.child_list, tile);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
tile->parent = NULL;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
if (display) {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -127,14 +127,14 @@ static void tile_unlink(grdev_tile *tile) {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
* we must take care to not leave them around. Therefore, whenever we
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
* unlink any part of a tree, we also destroy the parent, in case it's
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
* now stale.
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- * Parents are stale if they have no childs and either have no display
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ * Parents are stale if they have no children and either have no display
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
* or if they are intermediate nodes (i.e, they have a parent).
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
* This means, you can easily create trees, but you can never partially
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
* move or destruct them so far. They're always reduced to minimal form
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
* if you cut them. This might change later, but so far we didn't need
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
* partial destruction or the ability to move whole trees. */
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- if (parent->node.n_childs < 1 && (parent->parent || !parent->display))
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ if (parent->node.n_children < 1 && (parent->parent || !parent->display))
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
grdev_tile_free(parent);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
}
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -207,7 +207,7 @@ grdev_tile *grdev_tile_free(grdev_tile *tile) {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
case GRDEV_TILE_NODE:
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
assert(!tile->parent);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
assert(!tile->display);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- assert(tile->node.n_childs == 0);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ assert(tile->node.n_children == 0);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
break;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
}
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -472,10 +472,10 @@ static void display_cache_targets(grdev_display *display) {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
assert(display);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- /* depth-first with childs before parent */
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ /* depth-first with children before parent */
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
for (tile = tile_leftmost(display->tile);
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
tile;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- tile = tile_leftmost(tile->childs_by_node_next) ? : tile->parent) {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ tile = tile_leftmost(tile->children_by_node_next) ? : tile->parent) {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
if (tile->type == GRDEV_TILE_LEAF) {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
grdev_pipe *p;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -504,7 +504,7 @@ static void display_cache_targets(grdev_display *display) {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
} else {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
grdev_tile *child, *l;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- /* We're now at a node with all it's childs already
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ /* We're now at a node with all its children already
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
* computed (depth-first, child before parent). We
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
* first need to know the size of our tile, then we
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
* recurse into all leafs and update their cache. */
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
@@ -512,7 +512,7 @@ static void display_cache_targets(grdev_display *display) {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
tile->cache_w = 0;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
tile->cache_h = 0;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
- LIST_FOREACH(childs_by_node, child, tile->node.child_list) {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
+ LIST_FOREACH(children_by_node, child, tile->node.child_list) {
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
if (child->x + child->cache_w > tile->cache_w)
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
tile->cache_w = child->x + child->cache_w;
|
|
Zbigniew Jędrzejewski-Szmek |
62fe94 |
if (child->y + child->cache_h > tile->cache_h)
|