Exemplo n.º 1
0
Settings::Settings() {
  // Enable overlay by default for new users, but not for existing ones
  if( !QSettings().contains( KEY_OVERLAY_ENABLED ) ) {
    bool isNewUser = !HasAccount();
    SetOverlayEnabled( isNewUser );
  }
}
Exemplo n.º 2
0
int NFCDataBaseModule::CreateAccount(const std::string& strAccount, const std::string& strPassword)
{
    if (HasAccount(strAccount) <= 0)
    {
        char szExec[MAX_PATH] = { 0 };
        sprintf(szExec, "insert into %s ( Account, Password ) values ( '%s', '%s' )", mstrAccountTableName.c_str(), strAccount.c_str(), strPassword.c_str());

        m_pDataBaseDriver->OTLExec(szExec, motlConnect);
    }

    return -1;
}