config: add automatic closing to submaps (#11760)
* Allow submaps to auto reset to parent.
* Really should be a stack instead.
If hyprlang would allow for { } i would be so happy.
* Fixed: Somewhat better way to do it..
Lets you define what submap you want to go to instead.
* squash! Fixed: Somewhat better way to do it..
* God i hate cf..
* Force clang-format on the whole thing..
* Removed {}.
* Added tests
Tests and reset fix.
This commit is contained in:
parent
6a01c399a9
commit
d599513d4a
8 changed files with 102 additions and 26 deletions
|
|
@ -205,9 +205,9 @@ static SDispatchResult vkb(std::string in) {
|
|||
}
|
||||
|
||||
static SDispatchResult scroll(std::string in) {
|
||||
int by;
|
||||
double by;
|
||||
try {
|
||||
by = std::stoi(in);
|
||||
by = std::stod(in);
|
||||
} catch (...) { return SDispatchResult{.success = false, .error = "invalid input"}; }
|
||||
|
||||
Debug::log(LOG, "tester: scrolling by {}", by);
|
||||
|
|
@ -272,4 +272,4 @@ APICALL EXPORT void PLUGIN_EXIT() {
|
|||
g_mouse.reset();
|
||||
g_keyboard->destroy();
|
||||
g_keyboard.reset();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue