Skip to content

Commit

Permalink
#75
Browse files Browse the repository at this point in the history
  • Loading branch information
mvladic committed Nov 20, 2020
1 parent aeeef56 commit 291a949
Show file tree
Hide file tree
Showing 25 changed files with 55,468 additions and 54,733 deletions.
793 changes: 429 additions & 364 deletions modular-psu-firmware.eez-project

Large diffs are not rendered by default.

45 changes: 45 additions & 0 deletions src/eez/action_impl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,10 @@ void action_keypad_cancel() {
getActiveKeypad()->cancel();
}

void action_keypad_set_default() {
getActiveKeypad()->setDefault();
}

void action_keypad_sign() {
getActiveKeypad()->sign();
}
Expand Down Expand Up @@ -1399,6 +1403,47 @@ void action_show_labels_and_colors() {
pushPage(PAGE_ID_SYS_SETTINGS_LABELS_AND_COLORS);
}

void action_change_slot_label() {
}

void onSetChannelLabel(char *value) {
strcpy(g_channel->customLabel, value);
popPage();
}

void onSetChannelDefaultLabel(char *value) {
strcpy(g_channel->customLabel, value);
popPage();
}

void onSetChannelDefaultLabel() {
*g_channel->customLabel = 0;
popPage();
}

void action_change_channel_label() {
selectChannelByCursor();
Keypad::startPush(0, g_channel->getLabel(), 1, psu::CHANNEL_LABEL_MAX_CHARS, false, onSetChannelLabel, popPage, onSetChannelDefaultLabel);
}

void action_show_channel_color_picker() {
selectChannelByCursor();
pushPage(PAGE_ID_COLOR_PICKER);
}

void action_show_slot_color_picker() {
}

void action_pick_color() {
g_channel->customColor = 1 + getFoundWidgetAtDown().cursor;
popPage();
}

void action_pick_default_color() {
g_channel->customColor = 0;
popPage();
}

} // namespace gui
} // namespace eez

Expand Down
65,774 changes: 32,919 additions & 32,855 deletions src/eez/gui/document_simulator.cpp

Large diffs are not rendered by default.

Loading

0 comments on commit 291a949

Please sign in to comment.