Update references to master in the repository
authorMatthias Clasen <mclasen@redhat.com>
Mon, 29 Nov 2021 22:37:49 +0000 (17:37 -0500)
committerMatthias Clasen <mclasen@redhat.com>
Mon, 29 Nov 2021 22:37:49 +0000 (17:37 -0500)
17 files changed:
.gitlab-ci.yml
.gitlab-ci/flatpak-build.sh
.gitlab-ci/meson-html-report.py
.gitlab-ci/meson-junit-report.py
.gitlab-ci/run-style-check-diff.sh
.gitlab/issue_templates/Bug.md
.gitlab/issue_templates/Crash.md
CONTRIBUTING.md
README.md
build-aux/flatpak/org.gtk.Demo4.json
build-aux/flatpak/org.gtk.IconBrowser4.json
build-aux/flatpak/org.gtk.WidgetFactory4.json
demos/widget-factory/widget-factory.c
demos/widget-factory/widget-factory.ui
gtk/gtkapplication.c
gtk/gtksearchbar.c
gtk/gtkshortcutswindow.c

index 212c8576432afa958c8acd21d7c17c187b606dbb..57713e9d3c1025fb7d297f8ff2adfac4c1820e75 100644 (file)
@@ -221,11 +221,11 @@ vs2017-x64:
   extends: .flatpak-defaults
   when: manual
 
-# Only build Flatpak bundles automatically on master
-.flatpak-master:
+# Only build Flatpak bundles automatically on main
+.flatpak-main:
   extends: .flatpak-defaults
   only:
-    - master
+    - main
 
 flatpak-manual:demo:
   extends: .flatpak-manual
@@ -233,8 +233,8 @@ flatpak-manual:demo:
   variables:
     APPID: org.gtk.Demo4
 
-flatpak-master:demo:
-  extends: .flatpak-master
+flatpak-main:demo:
+  extends: .flatpak-main
   needs: []
   variables:
     APPID: org.gtk.Demo4
@@ -245,8 +245,8 @@ flatpak-manual:widget-factory:
   variables:
     APPID: org.gtk.WidgetFactory4
 
-flatpak-master:widget-factory:
-  extends: .flatpak-master
+flatpak-main:widget-factory:
+  extends: .flatpak-main
   needs: []
   variables:
     APPID: org.gtk.WidgetFactory4
@@ -257,8 +257,8 @@ flatpak-manual:icon-browser:
   variables:
     APPID: org.gtk.IconBrowser4
 
-flatpak-master:icon-browser:
-  extends: .flatpak-master
+flatpak-main:icon-browser:
+  extends: .flatpak-main
   needs: []
   variables:
     APPID: org.gtk.IconBrowser4
@@ -268,18 +268,18 @@ flatpak-master:icon-browser:
 # https://gitlab.gnome.org/GNOME/Initiatives/-/wikis/DevOps-with-Flatpak
 nightly demo:
     extends: '.publish_nightly'
-    dependencies: ['flatpak-master:demo']
-    needs: ['flatpak-master:demo']
+    dependencies: ['flatpak-main:demo']
+    needs: ['flatpak-main:demo']
 
 nightly factory:
     extends: '.publish_nightly'
-    dependencies: ['flatpak-master:widget-factory']
-    needs: ['flatpak-master:widget-factory']
+    dependencies: ['flatpak-main:widget-factory']
+    needs: ['flatpak-main:widget-factory']
 
 nightly icon-browser:
     extends: '.publish_nightly'
-    dependencies: ['flatpak-master:icon-browser']
-    needs: ['flatpak-master:icon-browser']
+    dependencies: ['flatpak-main:icon-browser']
+    needs: ['flatpak-main:icon-browser']
 
 static-scan:
   image: $FEDORA_IMAGE
@@ -346,4 +346,4 @@ publish-docs:
     - "curl -X POST -F token=${PAGES_TRIGGER_TOKEN} -F ref=docs-gtk-org https://gitlab.gnome.org/api/v4/projects/665/trigger/pipeline"
   only:
     refs:
-      - master
+      - main
index 661780067c78586bc30d3b74e550219009726afa..d739e9820e7047c5b822a2c2331b5477b0b7e9c0 100644 (file)
@@ -43,6 +43,6 @@ flatpak build-bundle \
         ${appid}
 
 # to be consumed by the nightly publish jobs
-if [[ $CI_COMMIT_BRANCH == master ]]; then
+if [[ $CI_COMMIT_BRANCH == main ]]; then
         tar cf repo.tar ${repodir}
 fi
index 2d67553fe5765b103cc66f62e2d204660ebead93..dd1f5666d3e37918c41586342974096265fa7413 100755 (executable)
@@ -268,7 +268,7 @@ aparser.add_argument('--job-id', metavar='ID',
                      default=None)
 aparser.add_argument('--branch', metavar='NAME',
                      help='Branch of the project being tested',
-                     default='master')
+                     default='main')
 aparser.add_argument('--output', metavar='FILE',
                      help='The output HTML file, stdout by default',
                      type=argparse.FileType('w', encoding='UTF-8'),
index 532305cdca4575b06b8ac3ac2103572c78499c45..d76f9d85e2bcd93414e2e1c469ecf02d5ceb7aa4 100755 (executable)
@@ -27,7 +27,7 @@ aparser.add_argument('--job-id', metavar='ID',
                      default='Unknown')
 aparser.add_argument('--branch', metavar='NAME',
                      help='Branch of the project being tested',
-                     default='master')
+                     default='main')
 aparser.add_argument('--output', metavar='FILE',
                      help='The output file, stdout by default',
                      type=argparse.FileType('w', encoding='UTF-8'),
index 42ef5d9feeffd766770442212d331cb376c28a20..a69fd77308bcf424796fe0c43473a4838af77e85 100755 (executable)
@@ -2,7 +2,7 @@
 
 set -e
 
-# We need to add a new remote for the upstream master, since this script could
+# We need to add a new remote for the upstream main, since this script could
 # be running in a personal fork of the repository which has out of date branches.
 if [ "${CI_PROJECT_NAMESPACE}" != "GNOME" ]; then
     echo "Retrieving the current upstream repository from ${CI_PROJECT_NAMESPACE}/${CI_PROJECT_NAME}..."
@@ -16,7 +16,7 @@ fi
 
 # Work out the newest common ancestor between the detached HEAD that this CI job
 # has checked out, and the upstream target branch (which will typically be
-# `upstream/master` or `upstream/gtk-3-24`).
+# `upstream/main` or `upstream/gtk-3-24`).
 #
 # `${CI_MERGE_REQUEST_TARGET_BRANCH_NAME}` is only defined if we’re running in
 # a merge request pipeline; fall back to `${CI_DEFAULT_BRANCH}` otherwise.
@@ -36,7 +36,7 @@ exit_status=$?
 echo ""
 echo "Note that clang-format output is advisory and cannot always match the"
 echo "GTK coding style, documented at:"
-echo "   https://gitlab.gnome.org/GNOME/gtk/blob/master/docs/CODING-STYLE"
+echo "   https://gitlab.gnome.org/GNOME/gtk/blob/main/docs/CODING-STYLE"
 echo "Warnings from this tool can be ignored in favour of the documented "
 echo "coding style, or in favour of matching the style of existing"
 echo "surrounding code."
index 4a47d305746065751f4a23bf399356389a15bb29..80142e8f91d4e01d5b389622e6a5c9d703da715e 100644 (file)
@@ -1,7 +1,7 @@
 <!--
   Please, read the CONTRIBUTING.md guide on how to file a new issue.
 
-  https://gitlab.gnome.org/GNOME/gtk/-/blob/master/CONTRIBUTING.md
+  https://gitlab.gnome.org/GNOME/gtk/-/blob/main/CONTRIBUTING.md
 -->
 ## Steps to reproduce
 <!--
index 2948affe1c03caf911772cffae9b57a6abe1420b..518ca1c987e4ec0ebc8a2a3d85ab1b039fd608bb 100644 (file)
@@ -1,7 +1,7 @@
 <!--
   Please, read the CONTRIBUTING.md guide on how to file a new issue.
 
-  https://gitlab.gnome.org/GNOME/gtk/-/blob/master/CONTRIBUTING.md
+  https://gitlab.gnome.org/GNOME/gtk/-/blob/main/CONTRIBUTING.md
 -->
 
 ## Steps to reproduce
index 80be9420fcc55505be63b6e294b586d6b97947ed..cde57475f0a7d82bd380bacab49895495eec1ebf 100644 (file)
@@ -256,7 +256,7 @@ people committing to GTK to follow a few rules:
 0. Always write a meaningful commit message. Changes without a sufficient
    commit message will be reverted.
 
-0. Never push to the `master` branch, or any stable branches, directly; you
+0. Never push to the `main` branch, or any stable branches, directly; you
    should always go through a merge request, to ensure that the code is
    tested on the CI infrastructure at the very least. A merge request is
    also the proper place to get a comprehensive code review from the core
index 5c4b46cf94454135721a8a01e7275e70676a1211..98f4122b7675db87d17f904b16b102ddf07dc084 100644 (file)
--- a/README.md
+++ b/README.md
@@ -1,7 +1,7 @@
 GTK — The GTK toolkit
 =====================
 
-[![Build status](https://gitlab.gnome.org/GNOME/gtk/badges/master/pipeline.svg)](https://gitlab.gnome.org/GNOME/gtk/-/commits/master)
+[![Build status](https://gitlab.gnome.org/GNOME/gtk/badges/main/pipeline.svg)](https://gitlab.gnome.org/GNOME/gtk/-/commits/main)
 
 General information
 -------------------
@@ -40,7 +40,7 @@ Nightly documentation can be found at
 
 Nightly flatpaks of our demos can be installed from the
 [GNOME Nightly](https://wiki.gnome.org/Apps/Nightly) repository:
-  - `flatpak remote-add --if-not-exists gnome-nightly https://nightly.gnome.org/gnome-nightly.flatpakrepo` 
+  - `flatpak remote-add --if-not-exists gnome-nightly https://nightly.gnome.org/gnome-nightly.flatpakrepo`
   - `flatpak install gnome-nightly org.gtk.Demo4`
   - `flatpak install gnome-nightly org.gtk.WidgetFactory4`
   - `flatpak install gnome-nightly org.gtk.IconBrowser4`
index 38d9a641c4fad5a775ba4b70c44aa20ef22554b8..e1813fa968fde5c58c77b3522436b88b56ee0a59 100644 (file)
             "sources" : [
                 {
                     "type" : "git",
-                    "url" : "https://gitlab.gnome.org/GNOME/gtk.git"
+                    "url" : "https://gitlab.gnome.org/GNOME/gtk.git",
+                    "branch" : "main"
                 }
             ]
         }
index a303812a81b8bdffec65618d50fcba7e4c7b7a16..908a197d7daf2dc68712beac4a9a56696f537a5f 100644 (file)
             "sources" : [
                 {
                     "type" : "git",
-                    "url" : "https://gitlab.gnome.org/GNOME/gtk.git"
+                    "url" : "https://gitlab.gnome.org/GNOME/gtk.git",
+                    "branch" : "main"
                 }
             ]
         }
index dbe1458299696833a4217e0d004ecebf6154c760..dadb6198e496ea339f4e839a10eff081dd4d4c30 100644 (file)
             "sources" : [
                 {
                     "type" : "git",
-                    "url" : "https://gitlab.gnome.org/GNOME/gtk.git"
+                    "url" : "https://gitlab.gnome.org/GNOME/gtk.git",
+                    "branch" : "main"
                 }
             ]
         }
index 9783c8d23d9cb6ec55f88ef0be715c9c1bca5629..db23a4884ddce211911dd2479f390412c1c5afaa 100644 (file)
@@ -78,6 +78,21 @@ change_theme_state (GSimpleAction *action,
                 NULL);
 }
 
+static void
+change_fullscreen (GSimpleAction *action,
+                   GVariant      *state,
+                   gpointer       user_data)
+{
+  GtkWindow *window = user_data;
+
+  if (g_variant_get_boolean (state))
+    gtk_window_fullscreen (window);
+  else
+    gtk_window_unfullscreen (window);
+
+  g_simple_action_set_state (action, state);
+}
+
 static GtkWidget *page_stack;
 
 static void
@@ -384,7 +399,7 @@ print_operation_done (GtkPrintOperation       *op,
       g_clear_error (&error);
       break;
     case GTK_PRINT_OPERATION_RESULT_APPLY:
-      break; 
+      break;
     case GTK_PRINT_OPERATION_RESULT_CANCEL:
       g_print ("Printing was canceled\n");
       break;
@@ -2012,11 +2027,12 @@ activate (GApplication *app)
   GMenuModel *model;
   static GActionEntry win_entries[] = {
     { "dark", NULL, NULL, "false", change_dark_state },
-    { "theme", NULL, "s", "'current'", change_theme_state }, 
+    { "theme", NULL, "s", "'current'", change_theme_state },
     { "transition", NULL, NULL, "true", change_transition_state },
     { "search", activate_search, NULL, NULL, NULL },
     { "delete", activate_delete, NULL, NULL, NULL },
     { "busy", get_busy, NULL, NULL, NULL },
+    { "fullscreen", NULL, NULL, "false", change_fullscreen },
     { "background", activate_background, NULL, NULL, NULL },
     { "open", activate_open, NULL, NULL, NULL },
     { "record", activate_record, NULL, NULL, NULL },
@@ -2182,7 +2198,7 @@ activate (GApplication *app)
   g_object_set_data (G_OBJECT (window), "searchbar", widget);
 
   widget = (GtkWidget *)gtk_builder_get_object (builder, "infobar");
-  g_signal_connect (widget, "response", G_CALLBACK (info_bar_response), NULL); 
+  g_signal_connect (widget, "response", G_CALLBACK (info_bar_response), NULL);
   g_object_set_data (G_OBJECT (window), "infobar", widget);
 
   dialog = (GtkWidget *)gtk_builder_get_object (builder, "info_dialog");
index e31629d986906416fded66c5979fecd23c4f4dd2..5b46570c8a99faeea75762cedae0fe4d1994ec22 100644 (file)
@@ -6,6 +6,10 @@
         <attribute name="label" translatable="yes">Get Busy</attribute>
         <attribute name="action">win.busy</attribute>
       </item>
+      <item>
+        <attribute name="label" translatable="yes">Fullscreen</attribute>
+        <attribute name="action">win.fullscreen</attribute>
+      </item>
       <submenu>
         <attribute name="label" translatable="yes">Style</attribute>
         <section>
index 1408c0d9d291ffce93f382a935351b2623675d44..4a33a5993663a36a2f83ad49219973f09bf240a7 100644 (file)
@@ -93,7 +93,7 @@
  *
  * ## A simple application
  *
- * [A simple example](https://gitlab.gnome.org/GNOME/gtk/tree/master/examples/bp/bloatpad.c)
+ * [A simple example](https://gitlab.gnome.org/GNOME/gtk/tree/main/examples/bp/bloatpad.c)
  * is available in the GTK source code repository
  *
  * `GtkApplication` optionally registers with a session manager of the
@@ -671,7 +671,7 @@ gtk_application_class_init (GtkApplicationClass *class)
  * If `application_id` is not %NULL, then it must be valid. See
  * `g_application_id_is_valid()`.
  *
- * If no application ID is given then some features (most notably application 
+ * If no application ID is given then some features (most notably application
  * uniqueness) will be disabled.
  *
  * Returns: a new `GtkApplication` instance
@@ -806,7 +806,7 @@ gtk_application_get_window_by_id (GtkApplication *application,
 
   g_return_val_if_fail (GTK_IS_APPLICATION (application), NULL);
 
-  for (l = priv->windows; l != NULL; l = l->next) 
+  for (l = priv->windows; l != NULL; l = l->next)
     {
       if (GTK_IS_APPLICATION_WINDOW (l->data) &&
           gtk_application_window_get_id (GTK_APPLICATION_WINDOW (l->data)) == id)
index 4394621d809b5567c478c6dd25363242c8145a94..7be0f004ef2f5c3f654e7f3ac54f2d2162529ffe 100644 (file)
@@ -69,7 +69,7 @@
  * The following example shows you how to create a more complex search
  * entry.
  *
- * [A simple example](https://gitlab.gnome.org/GNOME/gtk/tree/master/examples/search-bar.c)
+ * [A simple example](https://gitlab.gnome.org/GNOME/gtk/tree/main/examples/search-bar.c)
  *
  * # CSS nodes
  *
index 632ad964cd0abe19e7e9cc7e60e92435e5d40019..6eff6a0ef1da3172aeb57faf8266d25c82969fee 100644 (file)
@@ -68,7 +68,7 @@
  * are arranged in columns, and spread across several pages if there are too
  * many to find on a single page.
  *
- * The .ui file for this example can be found [here](https://gitlab.gnome.org/GNOME/gtk/tree/master/demos/gtk-demo/shortcuts-gedit.ui).
+ * The .ui file for this example can be found [here](https://gitlab.gnome.org/GNOME/gtk/tree/main/demos/gtk-demo/shortcuts-gedit.ui).
  *
  * # An example with multiple views:
  *
@@ -77,7 +77,7 @@
  * This example shows a `GtkShortcutsWindow` that has been configured to show only
  * the shortcuts relevant to the "stopwatch" view.
  *
- * The .ui file for this example can be found [here](https://gitlab.gnome.org/GNOME/gtk/tree/master/demos/gtk-demo/shortcuts-clocks.ui).
+ * The .ui file for this example can be found [here](https://gitlab.gnome.org/GNOME/gtk/tree/main/demos/gtk-demo/shortcuts-clocks.ui).
  *
  * # An example with multiple sections:
  *
@@ -86,7 +86,7 @@
  * This example shows a `GtkShortcutsWindow` with two sections, "Editor Shortcuts"
  * and "Terminal Shortcuts".
  *
- * The .ui file for this example can be found [here](https://gitlab.gnome.org/GNOME/gtk/tree/master/demos/gtk-demo/shortcuts-builder.ui).
+ * The .ui file for this example can be found [here](https://gitlab.gnome.org/GNOME/gtk/tree/main/demos/gtk-demo/shortcuts-builder.ui).
  */
 
 struct _GtkShortcutsWindow