mirror of
https://github.com/SerenityOS/serenity
synced 2024-09-06 08:56:40 +00:00
Base+Calculator: Add icons
Adds icons for Pi and Euler's Constant to the Constants menu.
This commit is contained in:
parent
9e81f60a2f
commit
adf6be45fb
BIN
Base/res/icons/calculator/eulers.png
Normal file
BIN
Base/res/icons/calculator/eulers.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3 KiB |
BIN
Base/res/icons/calculator/pi.png
Normal file
BIN
Base/res/icons/calculator/pi.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3 KiB |
|
@ -57,10 +57,10 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
|
|||
}));
|
||||
|
||||
auto& constants_menu = window->add_menu("&Constants");
|
||||
constants_menu.add_action(GUI::Action::create("&Pi", [&](auto&) {
|
||||
constants_menu.add_action(GUI::Action::create("&Pi", TRY(Gfx::Bitmap::try_load_from_file("/res/icons/calculator/pi.png")), [&](auto&) {
|
||||
widget->set_entry(KeypadValue { 31415926535, 10 });
|
||||
}));
|
||||
constants_menu.add_action(GUI::Action::create("&Euler's Constant", [&](auto&) {
|
||||
constants_menu.add_action(GUI::Action::create("&Euler's Constant", TRY(Gfx::Bitmap::try_load_from_file("/res/icons/calculator/eulers.png")), [&](auto&) {
|
||||
widget->set_entry(KeypadValue { 27182818284, 10 });
|
||||
}));
|
||||
|
||||
|
|
Loading…
Reference in a new issue