-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Killer feature update #14
base: main
Are you sure you want to change the base?
Conversation
Добавлены структуры в соответствии с UML-диаграммой
Добавлены исполняемые файлы в соответствии с UML-диаграммой
…k-education/2023_1_Rabotyagi into killer-feature-update
спать
…k-education/2023_1_Rabotyagi into killer-feature-update
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Клиент оцениваю на по 15 баллов
|
||
int result = init_app_settings(); | ||
|
||
int flag = 3; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
принимали бы тогда в enum тоже а не в int
break; | ||
} | ||
switch (flag) { | ||
case (int)LoginWindow::States::to_log_window: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
static_cast
|
||
class UserManager { | ||
private: | ||
static std::shared_ptr<User> instance; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
есть реализация синглтона, которая называется сигнлотоном Майерса, static std::shared_ptr<User> instance;
нужно положить в тело функции, тогда компилятор гарантирует, что если 2 потока одновременно вызовут getInstance не будет гонки на инициализации
static std::shared_ptr<QSettings> settings; | ||
UserManager() {} | ||
UserManager(const UserManager&); | ||
UserManager& operator=( UserManager& ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
const пропущен
#define REGISTRATIONWINDOW_H | ||
|
||
#include <QDialog> | ||
#include "../../controls/user_control/user_control.h" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
надо правильно настраивать include dir
|
||
try | ||
{ | ||
cpr::Response response = cpr::Get( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
блокирующийся вызов - не очень хорошо
struct Channel : Base | ||
{ | ||
unsigned int guild_id=0; | ||
std::string name=""; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
классы не нужно инициализировать явно
std::string password=""; | ||
std::string email=""; | ||
std::string last_login=""; | ||
unsigned int guild_id=-1; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
для unsigned лучше явно взять std::numeric_limits::max()
No description provided.