From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by sourceware.org (Postfix) with ESMTPS id 0E332385E010 for ; Fri, 28 Jan 2022 15:55:22 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 0E332385E010 Received: from mail-wr1-f69.google.com (mail-wr1-f69.google.com [209.85.221.69]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-445-MVhz8AnTOdigCUqIeAom_g-1; Fri, 28 Jan 2022 10:55:21 -0500 X-MC-Unique: MVhz8AnTOdigCUqIeAom_g-1 Received: by mail-wr1-f69.google.com with SMTP id g17-20020adfa591000000b001da86c91c22so2403527wrc.5 for ; Fri, 28 Jan 2022 07:55:21 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=rRQujnsq9O7MNAxKupVOyCZTDPb9bKJJOsIQGcAqMFY=; b=cv07qbGuO14RPUq3JLLJIl+qHpQnGG6Y2uBNtEwpzzrxnCDIS/meynOMOrsY8iAgzA ZHCWzhCxYXEZaFDFcgBN0RyOoETooV3SxAkYkcus4fuAkn7cig5Z1TxEtAYT4DDhuE+v 95u9Lu9yGRyMJ57/aBKSAAJU48nSPc/epZpHm74yOjtghLYvNG0wh3Rbl+T0emqzGHQK Fg+Ia/0ztI9VqNhMa+94uH6ego+hnZxz2unKpWeJqCa5lwZhf3dnuVJMv2b4nM/KHZlG zul/+zIXmTDvV1DMibl8D9eABRoY7mRNKvdBjTUV9fFnrHfijb7q1KhLw6iYaZiJ919t e33A== X-Gm-Message-State: AOAM533/IjsSfThrNkUOHYTmwM8XZmlmynvXq6FWipkJIHFbLRu++1iH Cr5yCY9hT0slyP+MNK/5xofQTpNYQmEBNOXDfpVXirSnPUTgssMw12RGxwco9btxdUu0mXr8lOr IZU6QG+3ZY/4qMRNbwUbupnZQA4U0fJNvRB+UwPp81g+rvTwjsxUGTvYjmdpdhgDOgGNXzS/gNQ == X-Received: by 2002:adf:fb0e:: with SMTP id c14mr7482197wrr.586.1643385319950; Fri, 28 Jan 2022 07:55:19 -0800 (PST) X-Google-Smtp-Source: ABdhPJwvtsyywaedv8WnDw83jdvJBQyzsFg8S1sq0nx4xkVTplxjSGhXPRK4rxg6HwVjOeJUpHAY1Q== X-Received: by 2002:adf:fb0e:: with SMTP id c14mr7482178wrr.586.1643385319640; Fri, 28 Jan 2022 07:55:19 -0800 (PST) Received: from localhost (host86-140-92-93.range86-140.btcentralplus.com. [86.140.92.93]) by smtp.gmail.com with ESMTPSA id n13sm4719050wrv.94.2022.01.28.07.55.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 28 Jan 2022 07:55:19 -0800 (PST) From: Andrew Burgess To: gdb-patches@sourceware.org Cc: Andrew Burgess Subject: [PATCH 4/7] gdb/tui: rename tui_layout_base::adjust_size to ::set_height Date: Fri, 28 Jan 2022 15:55:05 +0000 Message-Id: <2f065e15c56cd07fa74baec0df4ba3afa629658c.1643385021.git.aburgess@redhat.com> X-Mailer: git-send-email 2.25.4 In-Reply-To: References: MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII" X-Spam-Status: No, score=-11.8 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H2, SPF_HELO_NONE, SPF_NONE, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 28 Jan 2022 15:55:24 -0000 Rename tui_layout_base::adjust_size to tui_layout_base::set_height, the new name more accurately reflects what this member function does, and makes it easier for a later commit to add a new tui_layout_base::set_width member function. There should be no user visible changes after this commit. --- gdb/tui/tui-layout.c | 6 +++--- gdb/tui/tui-layout.h | 8 ++++---- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/gdb/tui/tui-layout.c b/gdb/tui/tui-layout.c index f8388e3fca5..4c355c79d65 100644 --- a/gdb/tui/tui-layout.c +++ b/gdb/tui/tui-layout.c @@ -118,7 +118,7 @@ tui_apply_current_layout () void tui_adjust_window_height (struct tui_win_info *win, int new_height) { - applied_layout->adjust_size (win->name (), new_height); + applied_layout->set_height (win->name (), new_height); } /* Set the current layout to LAYOUT. */ @@ -570,7 +570,7 @@ tui_layout_split::set_weights_from_heights () /* See tui-layout.h. */ tui_adjust_result -tui_layout_split::adjust_size (const char *name, int new_height) +tui_layout_split::set_height (const char *name, int new_height) { /* Look through the children. If one is a layout holding the named window, we're done; or if one actually is the named window, @@ -579,7 +579,7 @@ tui_layout_split::adjust_size (const char *name, int new_height) for (int i = 0; i < m_splits.size (); ++i) { tui_adjust_result adjusted - = m_splits[i].layout->adjust_size (name, new_height); + = m_splits[i].layout->set_height (name, new_height); if (adjusted == HANDLED) return HANDLED; if (adjusted == FOUND) diff --git a/gdb/tui/tui-layout.h b/gdb/tui/tui-layout.h index b9a5d9b898d..acea7ac8f64 100644 --- a/gdb/tui/tui-layout.h +++ b/gdb/tui/tui-layout.h @@ -75,9 +75,9 @@ class tui_layout_base return nullptr; } - /* Adjust the size of the window named NAME to NEW_HEIGHT, updating + /* Set the height of the window named NAME to NEW_HEIGHT, updating the sizes of the other windows around it. */ - virtual tui_adjust_result adjust_size (const char *name, int new_height) = 0; + virtual tui_adjust_result set_height (const char *name, int new_height) = 0; /* Remove some windows from the layout, leaving the command window and the window being passed in here. */ @@ -127,7 +127,7 @@ class tui_layout_window : public tui_layout_base return m_contents.c_str (); } - tui_adjust_result adjust_size (const char *name, int new_height) override + tui_adjust_result set_height (const char *name, int new_height) override { return m_contents == name ? FOUND : NOT_FOUND; } @@ -192,7 +192,7 @@ class tui_layout_split : public tui_layout_base void apply (int x, int y, int width, int height) override; - tui_adjust_result adjust_size (const char *name, int new_height) override; + tui_adjust_result set_height (const char *name, int new_height) override; bool top_boxed_p () const override; -- 2.25.4