1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
#include "Control.h" #include "String.h" #include <iostream> class Label : public Control { String str; public: void setDataDialog() override { std::cout << "Enter new label: "; char buffer[1024]; std::cin.getline(buffer, 1024); str = String(buffer); } };