- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
- 11
- 12
- 13
- 14
int __fastcall TForm1::iscomm(AnsiString str)
{
int i=1;
while (str[i]==' ')
i++;
if (str[i]=='#')
{
return 1;
}
else
{
return 0;
};
};
Нашли или выдавили из себя код, который нельзя назвать нормальным, на который без улыбки не взглянешь? Не торопитесь его удалять или рефакторить, — запостите его на говнокод.ру, посмеёмся вместе!
+147
int __fastcall TForm1::iscomm(AnsiString str)
{
int i=1;
while (str[i]==' ')
i++;
if (str[i]=='#')
{
return 1;
}
else
{
return 0;
};
};
+147
cout<<"enterX"<<endl;
cin >>x;
x = 0.125;
+147
uint32_t getuint32(char *p){
return (*p<<24)|(*(p+1)<<16)|(*(p+2)<<8)|(*(p+3));
}
+147
if(dOper1p->Caption == "-0")
dOper1p->Caption = "+0";
if(dOper2p->Caption == "-0")
dOper2p->Caption = "+0";
if(dOper1m->Caption == "-0.0")
dOper1m->Caption = "+0.0";
if(dOper2m->Caption == "-0.0")
dOper2m->Caption = "+0.0";
+179
public:
void* getThis(void){return this;};;;;
+162
ModuleManagerImpl::ModuleManagerImpl()
{
ModuleManager::loadPlugins();
Config config = ProfileDialog::profilesInfo();
#ifdef QUTIM_SINGLE_PROFILE
bool singleProfile = true;
#else
bool singleProfile = false;
#endif
singleProfile = config.value("singleProfile", singleProfile);
if (singleProfile) {
if (!config.hasChildGroup("profile")) {
QWidget *wizard = new ProfileCreationWizard(this, QString(), QString(), true);
wizard->setAttribute(Qt::WA_DeleteOnClose, true);
wizard->setAttribute(Qt::WA_QuitOnClose, false);
SystemIntegration::show(wizard);
} else {
config.beginGroup("profile");
if(ProfileDialog::acceptProfileInfo(config, QString())) {
QTimer::singleShot(0, this, SLOT(initExtensions()));
} else {
qWarning("Can't login");
QDialog *dialog = new ProfileDialog(config, this);
SystemIntegration::show(dialog);
}
config.endGroup();
}
} else {
QDialog *dialog = new ProfileDialog(config, this);
SystemIntegration::show(dialog);
}
}
не знаю как вам, а мне не нравится объявление singleProfile.
qutim/core/src/modulemanagerimpl.cpp
+158
for (int i = 0; i < n; i++)
if (i == n + 2)
//действия
=)
+162
setGeometry((int)(QApplication::desktop()->width() -
(QApplication::desktop()->width() -
(QApplication::desktop()->width() / 2)) * 1.5) / 2,
(int)(QApplication::desktop()->height() -
(QApplication::desktop()->height() -
(QApplication::desktop()->height() / 2)) * 1.5) / 2,
(int)((QApplication::desktop()->width() -
(QApplication::desktop()->width() / 2)) * 1.5),
(int)((QApplication::desktop()->height() -
(QApplication::desktop()->height() / 2)) * 1.5));
Center app window!
+169
void failware(void){0;return;};
+173
throw (i?getMainException():int());