Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hide demo tab when the demo is None #1456

Merged
merged 1 commit into from
Dec 22, 2020
Merged

Conversation

corranwebster
Copy link
Contributor

This adds an alternative group in demo file view for when demo is None.

Unfortunately we can't just hide the "Demo" tab, because dynamic hiding doesn't work.

This should essentially fix #1454

Copy link
Contributor

@aaronayres35 aaronayres35 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! (although code is a little clunky from tabs not working with visible_when but thats orthogonal)
I tested with the envisage examples that don't have a demo GUI component and everything looked correct (and I verified things still look the same when there is a demo GUI).

@corranwebster corranwebster merged commit 5a8f5d4 into master Dec 22, 2020
@corranwebster corranwebster deleted the enh/ets-demo-hide-demo branch December 22, 2020 09:06
yoda-vid added a commit to stephansanders/citation-overlap that referenced this pull request May 17, 2021
Expand the number of imported citations lists per session to 5 by incorporating two dynamically added import views and associated sheets. As TraitsUI does not appear to support dynamic tab addition currently (see enthought/traitsui#1456), create separate views, each with an additional tab, toggled based on a Trait. Add a button next to the extractor add button to add each tab, which becomes disabled after adding two new tabs/sheets. Add back a default extractor, this time a prompt for the user to select an extractor.
yoda-vid added a commit to stephansanders/citation-overlap that referenced this pull request May 18, 2021
Expand the number of imported citations lists per session to 5 by incorporating two dynamically added import views and associated sheets. As TraitsUI does not appear to support dynamic tab addition currently (see enthought/traitsui#1456), create separate views, each with an additional tab, toggled based on a Trait. Add a button next to the extractor add button to add each tab, which becomes disabled after adding two new tabs/sheets. Add back a default extractor, this time a prompt for the user to select an extractor.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Remove demo tab from the etsdemo application
2 participants