Commit Graph

13 Commits

Author SHA1 Message Date
Jeff Young 74acb76e7f Switch UNIT_BINDER and DIALOG_SHIM to local units.
The general idea is to support user-units inheritance.  The
UNIT_BINDER allows wrapped controls to inherit units from their
parent dialog, while KEYWAY_HOLDER and DIALOG_SHIM allow child
KEYWAY_HOLDERs or DIALOG_SHIMs to inherit units from their
parent.

The GetUserUnits() method signature has to move to KEYWAY_HOLDER
rather than KEYWAY_PLAYER (where it makes more sense) as it’s the
only common ancestor of KEYWAY_PLAYER and DIALOG_SHIM.

As long as we'll be using the UNIT_BINDER more widely, it also
makes sense to move evaluation and validation into it.

This commit also provides eeschema’s DIALOG_LABEL_EDITOR and
pcbnew’s DIALOG_TRACK_VIA_PROPERTIES and DIALOG_SET_GRID as
models of how to use the new user-units inheritance, eval, and
validation.

Fixes: lp:593795
* https://bugs.launchpad.net/kicad/+bug/593795

(cherry picked from commit c8bc53e)
2018-07-17 15:09:53 +01:00
Maciej Suminski 579d3f478d Renamed WX_UNIT_BINDER to UNIT_BINDER and moved to common/widgets
WX_ prefix should reserved for classes provieded by wxWidgets.
2017-11-24 21:15:40 +01:00
Tomasz Włostowski 9932ff32ae refactoring: wrapped boost::optional in OPT<> class for the purpose of easier transition to C++17 in the future 2017-11-03 23:59:02 +01:00
Mathias Grimmberger 2c23c4c3a9 Dropdown list in via properties dialog to select predefined via size 2017-09-18 10:28:08 +02:00
Mathias Grimmberger ffeba9de93 Change track width setting to dropbox 2017-08-25 16:46:49 +02:00
Tomasz Włostowski b964569db7 pcbnew: enable net selection combobox in Track/Via properties dialog 2017-07-27 16:21:54 +02:00
Jon Evans fd4e2b042c Refactor SELECTION, SELECTION_CONDITIONS, and context menus to common
SELECTION now holds EDA_ITEMs not BOARD_ITEMs so various places had to
change to casting the selected items to BOARD_ITEMs.

Fixed compilation warnings on clang (Tom)
2017-02-28 14:47:20 +01:00
Simon Richter ad088db6d2 Add more "override" markers. 2016-09-25 13:59:41 -04:00
Simon Richter 59c81976dc Explicitly mark overriding functions. 2016-09-24 14:53:15 -04:00
Maciej Suminski c4be379b31 Modified properties dialog to take advantage of BOARD_COMMIT class. 2016-09-12 11:50:06 +02:00
jean-pierre charras ee40137de7 more about dlg size fixes and osx fixes 2016-07-14 19:30:25 +02:00
Simon Richter 0e7f3bf366 Make forward declaration of SELECTION consistant with actual declaration. 2015-09-13 15:38:27 -04:00
Maciej Suminski 33e1797116 Tracks & vias properties dialog. 2015-07-09 13:35:51 +02:00