[mutter] window: Clean up coding style of meta_window_queue()
- From: Marge Bot <marge-bot src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter] window: Clean up coding style of meta_window_queue()
- Date: Mon, 7 Feb 2022 18:29:53 +0000 (UTC)
commit b5d873a8acc7b078b6b59c31c0a08c4cd7143d6a
Author: Jonas Ã…dahl <jadahl gmail com>
Date: Fri Jan 28 22:12:23 2022 +0100
window: Clean up coding style of meta_window_queue()
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2264>
src/core/window.c | 36 +++++++++++++++++++-----------------
1 file changed, 19 insertions(+), 17 deletions(-)
---
diff --git a/src/core/window.c b/src/core/window.c
index 1c65e7ab88..1b7464e750 100644
--- a/src/core/window.c
+++ b/src/core/window.c
@@ -2039,16 +2039,18 @@ meta_window_flush_calc_showing (MetaWindow *window)
}
void
-meta_window_queue (MetaWindow *window, guint queuebits)
+meta_window_queue (MetaWindow *window,
+ MetaQueueType queuebits)
{
- guint queuenum;
+ unsigned int queuenum;
/* Easier to debug by checking here rather than in the idle */
- g_return_if_fail (!window->override_redirect || (queuebits & META_QUEUE_MOVE_RESIZE) == 0);
+ g_return_if_fail (!window->override_redirect ||
+ (queuebits & META_QUEUE_MOVE_RESIZE) == 0);
- for (queuenum=0; queuenum<NUMBER_OF_QUEUES; queuenum++)
+ for (queuenum = 0; queuenum < NUMBER_OF_QUEUES; queuenum++)
{
- if (queuebits & 1<<queuenum)
+ if (queuebits & 1 << queuenum)
{
/* Data which varies between queues.
* Yes, these do look a lot like associative arrays:
@@ -2078,16 +2080,16 @@ meta_window_queue (MetaWindow *window, guint queuebits)
/* If the window already claims to be in that queue, there's no
* point putting it in the queue.
*/
- if (window->is_in_queues & 1<<queuenum)
+ if (window->is_in_queues & 1 << queuenum)
break;
meta_topic (META_DEBUG_WINDOW_STATE,
- "Putting %s in the %s queue",
- window->desc,
- meta_window_queue_names[queuenum]);
+ "Putting %s in the %s queue",
+ window->desc,
+ meta_window_queue_names[queuenum]);
/* So, mark it as being in this queue. */
- window->is_in_queues |= 1<<queuenum;
+ window->is_in_queues |= 1 << queuenum;
/* There's not a lot of point putting things into a queue if
* nobody's on the other end pulling them out. Therefore,
@@ -2096,13 +2098,13 @@ meta_window_queue (MetaWindow *window, guint queuebits)
*/
if (queue_later[queuenum] == 0)
- queue_later[queuenum] = meta_later_add
- (
- window_queue_later_when[queuenum],
- window_queue_later_handler[queuenum],
- GUINT_TO_POINTER(queuenum),
- NULL
- );
+ {
+ queue_later[queuenum] =
+ meta_later_add (window_queue_later_when[queuenum],
+ window_queue_later_handler[queuenum],
+ GUINT_TO_POINTER (queuenum),
+ NULL);
+ }
/* And now we actually put it on the queue. */
queue_pending[queuenum] = g_slist_prepend (queue_pending[queuenum],
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]