Andrew s/windows function

Windows to conversions:
- deleted window and add button and lineEdit;
- add WindowFunction;
- fix some bugs.