[Commits] [wesnoth/wesnoth] 6a0828: GUI2/Container Base: removed unnecessary virtual f...

GitHub noreply at github.com
Sat Aug 26 15:36:38 UTC 2017


  Branch: refs/heads/master
  Home:   https://github.com/wesnoth/wesnoth
  Commit: 6a0828eeaadc9fb98ebf75e2faf14b7c8545ea14
      https://github.com/wesnoth/wesnoth/commit/6a0828eeaadc9fb98ebf75e2faf14b7c8545ea14
  Author: Charles Dang <exodia339 at gmail.com>
  Date:   2017-08-26 (Sat, 26 Aug 2017)

  Changed paths:
    M src/gui/widgets/container_base.cpp
    M src/gui/widgets/container_base.hpp

  Log Message:
  -----------
  GUI2/Container Base: removed unnecessary virtual function slated for removal


  Commit: ca0a9b2010b9784bb54674762f6796832feb68c4
      https://github.com/wesnoth/wesnoth/commit/ca0a9b2010b9784bb54674762f6796832feb68c4
  Author: Charles Dang <exodia339 at gmail.com>
  Date:   2017-08-27 (Sun, 27 Aug 2017)

  Changed paths:
    M src/gui/widgets/grid.cpp
    M src/gui/widgets/grid.hpp

  Log Message:
  -----------
  GUI2/Grid: refactor handling of cell widgets

Does a few things:
* Use a unique_ptr to manage the grid::child widget pointer.
* Added a non-throwing move ctor to grid::child to allow vector::resize to successfully execute
  without copying members.
* Added a grid::child::free_widget function used in grid::swap_child in order to ensure the child's
  widget is always managed by a smart pointer. It's also necessary to avoid crashes arising from
  attempting to create a new unique_ptr from the result of grid::child::get_widget, as the resulting
  object is still managed by the child object's unique_ptr.


  Commit: 74935c492d9477d54d850c57dfee1e0ff534bac7
      https://github.com/wesnoth/wesnoth/commit/74935c492d9477d54d850c57dfee1e0ff534bac7
  Author: Charles Dang <exodia339 at gmail.com>
  Date:   2017-08-27 (Sun, 27 Aug 2017)

  Changed paths:
    M src/gui/widgets/scrollbar_container.cpp
    M src/gui/widgets/scrollbar_container.hpp

  Log Message:
  -----------
  GUI2/Scrollbar Container: manage content grid with a unique ptr


  Commit: 9bb6ab0eab103a7e250f718fcb2d6d8086a253b4
      https://github.com/wesnoth/wesnoth/commit/9bb6ab0eab103a7e250f718fcb2d6d8086a253b4
  Author: Charles Dang <exodia339 at gmail.com>
  Date:   2017-08-27 (Sun, 27 Aug 2017)

  Changed paths:
    M src/gui/widgets/scrollbar_container.hpp

  Log Message:
  -----------
  GUI2/Scrollbar Container: marked destructor as virtual, as it should be


Compare: https://github.com/wesnoth/wesnoth/compare/683c95c53f0a...9bb6ab0eab10


More information about the Commits mailing list