Skip to content

Commit

Permalink
Merge branch 'unleashed' of https://github.com/RogueMaster/flipperzer…
Browse files Browse the repository at this point in the history
…o-firmware-wPlugins into unleashed
  • Loading branch information
RogueMaster committed Aug 16, 2022
2 parents 497f351 + 1ce0707 commit b4caa0b
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@ const char* const battery_view_count_text[BATTERY_VIEW_COUNT] = {
};
const uint32_t displayBatteryPercentage_value[BATTERY_VIEW_COUNT] = {0, 1, 2, 3, 4};

uint8_t origBattDisp_value = 0;

#define DUMBMODE_COUNT 2
const char* const dumbmode_text[DUMBMODE_COUNT] = {
"OFF",
Expand Down Expand Up @@ -77,6 +79,7 @@ static void desktop_settings_scene_start_dumbmode_changed(VariableItem* item) {
void desktop_settings_scene_start_on_enter(void* context) {
DesktopSettingsApp* app = context;
VariableItemList* variable_item_list = app->variable_item_list;
origBattDisp_value = app->settings.displayBatteryPercentage;

VariableItem* item;
uint8_t value_index;
Expand Down Expand Up @@ -174,4 +177,9 @@ void desktop_settings_scene_start_on_exit(void* context) {
DesktopSettingsApp* app = context;
variable_item_list_reset(app->variable_item_list);
SAVE_DESKTOP_SETTINGS(&app->settings);

if(app->settings.displayBatteryPercentage != origBattDisp_value)
{
furi_hal_power_reset();
}
}
6 changes: 3 additions & 3 deletions documentation/HowToBuild.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ $ git clone --recursive https://github.com/RogueMaster/flipperzero-firmware-wPlu

# Build on Linux/macOS

Check out `documentation/fbt.md` for details on building and flashing firmware.
Check out [documentation/fbt.md](documentation/fbt.md) for details on building and flashing firmware.

### Compile everything for development

Expand All @@ -40,7 +40,7 @@ If compilation fails, make sure all submodules are all initialized. Either clone

# Build on Linux/macOS

Check out `documentation/fbt.md` for details on building and flashing firmware.
Check out [documentation/fbt.md](documentation/fbt.md) for details on building and flashing firmware.

### Compile everything for development

Expand Down Expand Up @@ -85,4 +85,4 @@ Check `dist/` for build outputs.

Use **`flipper-z-{target}-full-{suffix}.dfu`** to flash your device.

If compilation fails, make sure all submodules are all initialized. Either clone with `--recursive` or use `git submodule update --init --recursive`.
If compilation fails, make sure all submodules are all initialized. Either clone with `--recursive` or use `git submodule update --init --recursive`.

0 comments on commit b4caa0b

Please sign in to comment.