mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 19:57:35 +00:00
Calculator: Add a simple calculator app
Closes https://github.com/SerenityOS/serenity/issues/319
This commit is contained in:
parent
79f867238a
commit
ccb482d1a7
10 changed files with 611 additions and 0 deletions
19
Applications/Calculator/main.cpp
Normal file
19
Applications/Calculator/main.cpp
Normal file
|
@ -0,0 +1,19 @@
|
|||
#include "CalculatorWidget.h"
|
||||
#include <LibGUI/GApplication.h>
|
||||
#include <LibGUI/GWindow.h>
|
||||
|
||||
int main(int argc, char** argv)
|
||||
{
|
||||
GApplication app(argc, argv);
|
||||
|
||||
auto* window = new GWindow;
|
||||
window->set_title("Calculator");
|
||||
window->set_resizable(false);
|
||||
window->set_rect({ 300, 200, 254, 213 });
|
||||
|
||||
auto* calc_widget = new CalculatorWidget(nullptr);
|
||||
window->set_main_widget(calc_widget);
|
||||
|
||||
window->show();
|
||||
return app.exec();
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue