Skip to content
This repository was archived by the owner on Jan 16, 2021. It is now read-only.

extend number-checker component#101

Open
LennyLinux wants to merge 2 commits intomozilla:masterfrom
LennyLinux:master
Open

extend number-checker component#101
LennyLinux wants to merge 2 commits intomozilla:masterfrom
LennyLinux:master

Conversation

@LennyLinux
Copy link
Copy Markdown

@mozilla/appmaker#503

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

That onChange event is used by the designer to see when it should save the app. What are you trying to do here?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

i added a checkbox in the editable panel to switch between input field and subscription channel as compare value source.

if you connect the subscription channel, the checkbox should be checked.
if you disconnect the subscription channel, the checkbox should be unchecked.

or

if you check the checkbox the subscription channel should be connected
if you uncheck the checkbox the subscription channel should be disconnected

here I tried to get notified if a subscription channel is (dis)connected.
atm there is no dedicated subscription-channel-connected-event, just a generic change event if a channel is connected. bit of a hack.

maybe the checkbox is needless and the present subscription channel is is clear enough?
that would simplify the code a lot.

connected

screen shot 2013-11-14 at 11 09 29 pm

disconnected

screen shot 2013-11-14 at 11 09 46 pm

@LennyLinux
Copy link
Copy Markdown
Author

I reverted the previous commit.
The component now simply provides an subscription channel setNumber
which sets the checkAgainst attribute.

From ui perspective it might be a good idea to disable the input field when the setNumber channel is connected ?

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants