mirror of
https://github.com/clangen/musikcube.git
synced 2024-10-02 13:02:35 +00:00
Fixed the accidental double Crypt.
This commit is contained in:
parent
a9185a9795
commit
ec480b400a
@ -91,7 +91,7 @@ void MainMenuController::OnAddLibraryLocal(MenuItemRef menuItem)
|
|||||||
void MainMenuController::OnAddLibraryRemote(MenuItemRef menuItem)
|
void MainMenuController::OnAddLibraryRemote(MenuItemRef menuItem)
|
||||||
{
|
{
|
||||||
win32cpp::TopLevelWindow popupDialog(_T("Add remote library"));
|
win32cpp::TopLevelWindow popupDialog(_T("Add remote library"));
|
||||||
popupDialog.SetMinimumSize(Size(300, 150));
|
popupDialog.SetMinimumSize(Size(300, 220));
|
||||||
|
|
||||||
dialog::AddLibraryController addLibrary(popupDialog,musik::core::LibraryFactory::Remote);
|
dialog::AddLibraryController addLibrary(popupDialog,musik::core::LibraryFactory::Remote);
|
||||||
|
|
||||||
|
@ -89,7 +89,13 @@ void AddLibraryController::OnOK(win32cpp::Button* button){
|
|||||||
prefs.SetString("address",this->view->remoteHost->Caption().c_str());
|
prefs.SetString("address",this->view->remoteHost->Caption().c_str());
|
||||||
prefs.SetString("port",this->view->remotePort->Caption().c_str());
|
prefs.SetString("port",this->view->remotePort->Caption().c_str());
|
||||||
prefs.SetString("username",this->view->username->Caption().c_str());
|
prefs.SetString("username",this->view->username->Caption().c_str());
|
||||||
prefs.SetString("password",UTF8_TO_UTF(musik::core::Crypt::Encrypt(UTF_TO_UTF8(this->view->remotePort->Caption().c_str()),musik::core::Crypt::StaticSalt())).c_str());
|
|
||||||
|
utfstring password(
|
||||||
|
UTF8_TO_UTF(
|
||||||
|
musik::core::Crypt::Encrypt(
|
||||||
|
UTF_TO_UTF8(this->view->password->Caption()),musik::core::Crypt::StaticSalt())));
|
||||||
|
|
||||||
|
prefs.SetString("password",password.c_str());
|
||||||
}
|
}
|
||||||
|
|
||||||
library->Startup();
|
library->Startup();
|
||||||
|
@ -85,7 +85,7 @@ void EditUserController::OnOK(win32cpp::Button* button){
|
|||||||
// TODO: Save user
|
// TODO: Save user
|
||||||
this->server->CreateUser(
|
this->server->CreateUser(
|
||||||
this->view->username->Caption(),
|
this->view->username->Caption(),
|
||||||
UTF8_TO_UTF(musik::core::Crypt::Encrypt( musik::core::ConvertUTF8(this->view->password->Caption()),musik::core::Crypt::StaticSalt())),
|
this->view->password->Caption(),
|
||||||
this->view->nickname->Caption()
|
this->view->nickname->Caption()
|
||||||
);
|
);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user