Startup items can be assigned connections #1520

Merged
merged 22 commits into from Jun 17, 2016

Conversation

Projects
None yet
1 participant
@rhwood
Contributor

rhwood commented Jun 17, 2016

This is a starting point for allowing connections to be assigned to actions at startup.

  • Allow startup items that wrap actions that need connections to function properly to do so.
  • Define an interface jmri.jmrix.swing.SystemConnectionAction to add to an action that needs a connection so startup items can discover the need to assign a connection.
  • Make some LocoNet tools extend jmri.jmrix.swing.SystemConnectionAction.
  • Remove unneeded population of startup item actions lists.
  • Further migration of startup classes into the apps.startup package from apps.

rhwood added some commits Jun 11, 2016

Keep selection when reordering startup items.
Also document methods firing a property change event.
Allow pauses processing startup items
Add a StartupModel that allows users to insert a delay between two
startup items (like two scripts).
Add Tooltips to Startup Items
The TableModel already supported Tooltips, but the table did not render
them.
Override toString to provide HTML Tooltips for more complex Startup
Items.
Further consolidation of Startup items into apps.startup package.
Also includes some initial experimentation on an Interface for
determining which Actions need to be bound to a system connection.
Merge remote-tracking branch 'JMRI/master' into startup-issues
# Conflicts:
#	java/src/apps/AbstractActionModel.java
#	java/src/apps/startup/AbstractStartupModel.java
Further clarification of binding connections to startup items
- Return Set instead of Array of connections (Arrays and generics don’t
mix well)
- Retain systemPrefix instead of memo in model
- Factory rejiggers connections list as user changes action in model
The action model list populates on demand.
As a consequence of this, its no longer necessary to explicitly
populate it when starting JMRI.
Add method to get the default instance.
StartupActionModelUtil.getDefault() ensures there is a default
instance, so usages of it do not need to check for null instances.
Bind startup actions to specific connections.
No attempt is made to ensure actions bound to a removed connection are
fixed.
Actions bound to a nonexistent connection may cause crashes, unexpected
errors, or other bad behavior.

@rhwood rhwood added the Enhancement label Jun 17, 2016

@rhwood rhwood added this to the 4.5.1 milestone Jun 17, 2016

@rhwood rhwood merged commit a8a9158 into JMRI:master Jun 17, 2016

2 checks passed

continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@rhwood

This comment has been minimized.

Show comment
Hide comment
@rhwood

rhwood Jun 17, 2016

Contributor

Initial work towards addressing #1383.

Contributor

rhwood commented Jun 17, 2016

Initial work towards addressing #1383.

@rhwood

This comment has been minimized.

Show comment
Hide comment
@rhwood

rhwood Jun 21, 2016

Contributor

Further work on UI is in #1525.

Contributor

rhwood commented Jun 21, 2016

Further work on UI is in #1525.

rhwood added a commit to JMRI/website that referenced this pull request Jun 21, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment