1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-20 03:35:07 +00:00
serenity/LibGUI/GInputBox.h
Andreas Kling a6538feed1 LibGUI: Add GInputBox for getting a string from a modal dialog.
Use this to implement some of the toolbar actions in IRCClient. :^)
2019-03-19 01:41:00 +01:00

18 lines
401 B
C++

#pragma once
#include <LibGUI/GDialog.h>
class GInputBox : public GDialog {
public:
enum ExecResult { ExecOK = 0, ExecCancel = 1 };
explicit GInputBox(const String& prompt, const String& title, GObject* parent = nullptr);
virtual ~GInputBox() override;
String text_value() const { return m_text_value; }
private:
void build();
String m_prompt;
String m_text_value;
};