1. 17 Jan, 2019 2 commits
    • Jonas Ådahl's avatar
      menu: Force resize when remapping · 3e586a82
      Jonas Ådahl authored
      A menu will be clamped to the work area as a side effect of the
      move_to_rect() logic if the resize anchor flags was set. For it to work
      a second time, the initial size needs to be the actual menu size before
      being clamped again. Achieve this by forcing a size recalculation before
      showing the menu.
      3e586a82
    • Jonas Ådahl's avatar
      menu: Don't constrain initial menu size · 00486efd
      Jonas Ådahl authored
      Don't constrain the initial menu size by the work area of some monitor;
      instead let the move_to_rect() logic in the backend do the constraining.
      This fixes two things:
      
      1) The anchor delta provided to the backend will not be invalid. The
      delta is calculated by looking at the active menu item, calculating the
      offset given that, but since we clamped the window size before showing
      the window, the delta became invalid. This caused visible issues when
      the delta was large enough to make the initially calculated popup window
      geometry to be placed outside the geometry of the parent window, which
      is a violation of the Wayland protocol.
      
      2) The scroll offset to be correct when receiving the positioning
      feedback. While the scroll offset was based on the pre-clamped window
      size, the feedback, which was used to calculate the new offset, was not,
      causing the scroll offset to be clamped as well.
      00486efd
  2. 08 Jan, 2019 2 commits
  3. 07 Jan, 2019 3 commits
  4. 06 Jan, 2019 1 commit
  5. 03 Jan, 2019 2 commits
    • Matthias Clasen's avatar
      Check for the session bus before using it · 4eee51b0
      Matthias Clasen authored
      Patch by Chris Allen, #475
      4eee51b0
    • Orivej Desh's avatar
      Zero-fill new GtkTextIter · f6bc2415
      Orivej Desh authored
      iter_init_common() is used on uninitialized GtkTextIter, and since neither it
      nor its callers initiliaze its padding fields, they contain garbage.
      
      This is a problem for Go - which checks that structs passed to C functions do
      not contain pointers to Go-allocated memory - when the garbage happens to be
      such a pointer.  Although Go zero-fills all GtkTextIter that it allocates, this
      does not help when GTK functions such as insert_pixbuf_or_widget_segment called
      for gtk_text_buffer_create_child_anchor copy garbage from their stack-allocated
      GtkTextIter into a clean iter.  To work around this a GtkTextIter has to be
      discraded after use in text buffer anchor inserting functions:
      https://github.com/gotk3/gotk3/pull/307
      f6bc2415
  6. 02 Jan, 2019 1 commit
  7. 30 Dec, 2018 1 commit
    • Daniel Boles's avatar
      Fix 'Fix "A11y: Add support for AtkTableCell"'... · 63e0eb5d
      Daniel Boles authored
      ...since one of the "fixes" there was wrong, at least cosmetically:
      .get_position() is declared as returning a gboolean, which is in fact an
      int in practice, but we should say what we mean, like we already did.
      63e0eb5d
  8. 26 Dec, 2018 1 commit
    • Chun-wei Fan's avatar
      Fix "A11y: Add support for AtkTableCell" · c876c74e
      Chun-wei Fan authored
      Make sure that the return types of the vfuncs match the ones that are
      specified for post-atk-2.11.x AtkTableCellIface, since we already
      require atk-2.15.1 and later.
      c876c74e
  9. 22 Dec, 2018 1 commit
    • Tomasz Miąsko's avatar
      Annotate values of PRIORITY constants · d3b6d16d
      Tomasz Miąsko authored
      g-ir-scanner incorrectly evaluates macro definition that include
      references to other macro definitions. Provide a correct value as an
      annotation.
      
      Differences in generated gir files:
      
      ```diff
      @@ -19017 +19017 @@
      -    <constant name="PRIORITY_REDRAW" value="20" c:type="GDK_PRIORITY_REDRAW">
      +    <constant name="PRIORITY_REDRAW" value="120" c:type="GDK_PRIORITY_REDRAW">
      @@ -74229,3 +74229,3 @@
           </constant>
      -    <constant name="PRIORITY_RESIZE" value="10" c:type="GTK_PRIORITY_RESIZE">
      +    <constant name="PRIORITY_RESIZE" value="110" c:type="GTK_PRIORITY_RESIZE">
             <doc xml:space="preserve">Use this priority for functionality related to size allocation.
      @@ -106786,3 +106786,3 @@
           <constant name="TEXT_VIEW_PRIORITY_VALIDATE"
      -              value="5"
      +              value="125"
                     c:type="GTK_TEXT_VIEW_PRIORITY_VALIDATE">
      ```
      d3b6d16d
  10. 21 Dec, 2018 1 commit
  11. 20 Dec, 2018 2 commits
  12. 19 Dec, 2018 1 commit
    • Carlos Garnacho's avatar
      revealer: Fully set the target state if unmapped during animation · 32ad0ffa
      Carlos Garnacho authored
      If the revealer is told do animate and then unrealize itself, we do
      (correctly) stop the animation, but used to do a shortcut where we
      just set the target state as current.
      
      Other things are dependent on the animation properly finishing though,
      like the contained widget child visibility. This may lead to inconsistent
      state where gtk_revealer_get_child_revealed() returns TRUE but the child
      widget is unmapped, or vice-versa.
      
      Fully finish the animation here, so the child state is coherent the next
      time the revealer is mapped. We can also skip notifying on the property
      since it will be handled by gtk_revealer_set_position().
      
      Closes: gnome-control-center#316
      32ad0ffa
  13. 18 Dec, 2018 1 commit
    • Daniel Boles's avatar
      Revealer: Don’t (under)allocate child if not shown · d179b066
      Daniel Boles authored
      If the child is not (partly) revealed, don’t allocate it, or we spam the
      console with warnings about giving negative width to children’s gadgets.
      We can check :child-visible, which is FALSE if (current&target)_pos == 0
      
      Close #1057
      d179b066
  14. 17 Dec, 2018 2 commits
  15. 14 Dec, 2018 1 commit
  16. 12 Dec, 2018 2 commits
  17. 10 Dec, 2018 7 commits
  18. 08 Dec, 2018 2 commits
  19. 07 Dec, 2018 2 commits
  20. 06 Dec, 2018 2 commits
  21. 05 Dec, 2018 1 commit
  22. 04 Dec, 2018 2 commits
    • Daniel Boles's avatar
      Box, Grid: Improve various bits of documentation · b0fdaf3b
      Daniel Boles authored
      Issue #1495 showed that the docs of GtkGrid retain outdated implications
      that (as was once, but is no longer, the case) it is intended to replace
      GtkBox, by discussing HfW and widget properties in a way that suggests
      GtkBox can't handle them. But of course it does, and it's preferable for
      simple single-row/column cases. Worse, we said GtkGrid “provides exactly
      the same functionality” for the latter case, but the original point of
      that Issues was that it doesn’t, at least for CSS positional selectors!
      
      Box:
      • Use an actually meaningful @Short_description.
      • Remove unhelpful @See_also references to unrelated containers.
      • Remove references to “rectangular area”: it might be another shape
        via CSS, or “rectangular” might falsely imply 2 dimensions of children.
      • Mention Orientable:orientation.
      • Emphasise usefulness of :[hv]align for allocating in the other axis.
      • Don’t say that Grid “provides exactly the same functionality” for a
        single row or column, since (A) it is overkill for that case and (B)
        said Issue proved that it *doesn’t* for CSS child order, for example.
      • Note in the child properties that are remove in master that we have
        better, preferred alternatives available now in GtkWidget/CSS props.
        There’s no nice way to deprecate these, though they’re gone in GTK+ 4.
      • Correct a copy-paste-o from the blurb of :expand to :fill.
      
      Grid:
      • Remove references to deprecated widgets: GtkTable and Gtk[HV]Box.
      • Don’t dwell on widget properties and height-for-width in a way that
        wrongly implies that Box can’t handle those (or Grid can better). In
        fact, just get rid of that bit altogether: Box handles them fine, and
        Table is so old as to be not worth mentioning (in anything except the
        2 => 3 migration guide) and points to Grid in its deprecation notice.
      • Point to GtkBox as being preferred for the simple row/column use case.
      b0fdaf3b
    • Matthias Clasen's avatar
      emoji chooser: Actually force Emoji presentation · b74e3209
      Matthias Clasen authored
      The previous commit was using the text presentation selector
      instead of the Emoji one. Oops.
      b74e3209