Procházet zdrojové kódy

优化登录页面效果

张洋 před 1 týdnem
rodič
revize
c9163eb862
26 změnil soubory, kde provedl 36 přidání a 29 odebrání
  1. binární
      bin/Win32/Debug/zhipuzi_pos_windows/DuiLib_d.dll
  2. binární
      bin/Win32/Debug/zhipuzi_pos_windows/skin/Combo_nor.bmp
  3. binární
      bin/Win32/Debug/zhipuzi_pos_windows/skin/Combo_over.bmp
  4. binární
      bin/Win32/Debug/zhipuzi_pos_windows/skin/Headerctrl_Sperator.bmp
  5. binární
      bin/Win32/Debug/zhipuzi_pos_windows/skin/Login_Combox_Click.png
  6. binární
      bin/Win32/Debug/zhipuzi_pos_windows/skin/Login_Combox_Hover.png
  7. binární
      bin/Win32/Debug/zhipuzi_pos_windows/skin/Login_Combox_Normal.png
  8. binární
      bin/Win32/Debug/zhipuzi_pos_windows/skin/frame_btn_close_disable.bmp
  9. binární
      bin/Win32/Debug/zhipuzi_pos_windows/skin/frame_btn_close_down.bmp
  10. binární
      bin/Win32/Debug/zhipuzi_pos_windows/skin/frame_btn_close_hot.bmp
  11. binární
      bin/Win32/Debug/zhipuzi_pos_windows/skin/frame_btn_close_normal.bmp
  12. binární
      bin/Win32/Debug/zhipuzi_pos_windows/skin/frame_btn_max.bmp
  13. binární
      bin/Win32/Debug/zhipuzi_pos_windows/skin/frame_btn_min.bmp
  14. binární
      bin/Win32/Debug/zhipuzi_pos_windows/skin/headerctrl_down.bmp
  15. binární
      bin/Win32/Debug/zhipuzi_pos_windows/skin/headerctrl_hot.bmp
  16. binární
      bin/Win32/Debug/zhipuzi_pos_windows/skin/headerctrl_normal.bmp
  17. 13 15
      bin/Win32/Debug/zhipuzi_pos_windows/skin/login.xml
  18. binární
      bin/Win32/Debug/zhipuzi_pos_windows/skin/tab_back.bmp
  19. binární
      bin/Win32/Debug/zhipuzi_pos_windows/skin/tab_hot.bmp
  20. binární
      bin/Win32/Debug/zhipuzi_pos_windows/skin/tab_normal.bmp
  21. binární
      bin/Win32/Debug/zhipuzi_pos_windows/skin/tab_select.bmp
  22. 3 9
      bin/Win32/Debug/zhipuzi_pos_windows/skin/update.xml
  23. binární
      bin/Win32/Debug/zhipuzi_pos_windows/skin/winbk.bmp
  24. binární
      dll/debug/DuiLib_d.dll
  25. binární
      temp/link/Win32/Debug/DuiLib/DuiLib_d.pdb
  26. 20 5
      zhipuzi_pos_windows/wnd/CLoginWnd.cpp

binární
bin/Win32/Debug/zhipuzi_pos_windows/DuiLib_d.dll


binární
bin/Win32/Debug/zhipuzi_pos_windows/skin/Combo_nor.bmp


binární
bin/Win32/Debug/zhipuzi_pos_windows/skin/Combo_over.bmp


binární
bin/Win32/Debug/zhipuzi_pos_windows/skin/Headerctrl_Sperator.bmp


binární
bin/Win32/Debug/zhipuzi_pos_windows/skin/Login_Combox_Click.png


binární
bin/Win32/Debug/zhipuzi_pos_windows/skin/Login_Combox_Hover.png


binární
bin/Win32/Debug/zhipuzi_pos_windows/skin/Login_Combox_Normal.png


binární
bin/Win32/Debug/zhipuzi_pos_windows/skin/frame_btn_close_disable.bmp


binární
bin/Win32/Debug/zhipuzi_pos_windows/skin/frame_btn_close_down.bmp


binární
bin/Win32/Debug/zhipuzi_pos_windows/skin/frame_btn_close_hot.bmp


binární
bin/Win32/Debug/zhipuzi_pos_windows/skin/frame_btn_close_normal.bmp


binární
bin/Win32/Debug/zhipuzi_pos_windows/skin/frame_btn_max.bmp


binární
bin/Win32/Debug/zhipuzi_pos_windows/skin/frame_btn_min.bmp


binární
bin/Win32/Debug/zhipuzi_pos_windows/skin/headerctrl_down.bmp


binární
bin/Win32/Debug/zhipuzi_pos_windows/skin/headerctrl_hot.bmp


binární
bin/Win32/Debug/zhipuzi_pos_windows/skin/headerctrl_normal.bmp


+ 13 - 15
bin/Win32/Debug/zhipuzi_pos_windows/skin/login.xml

@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<Window size="520,430" caption="0,0,0,36" roundcorner="4,4" shadowsize="3" showshadow="true">
+<Window size="600,480" caption="0,0,0,36" roundcorner="4,4" shadowsize="3" showshadow="true">
 	<Font shared="true" id="0" name="微软雅黑" size="16" default="true" />
 	<Font id="1" name="微软雅黑" size="40" />
 	<Font id="2" name="微软雅黑" size="18" />
@@ -11,37 +11,35 @@
 			<Button name="closebtn" padding="0,13,15,0" width="16" height="16" tooltip="关闭" normalimage="file='close_normal.png'" hotimage="file='close_hover.png'" pushedimage="file='close_normal.png'"/>
 		</HorizontalLayout>
 		
-		<HorizontalLayout height="90">
+		<HorizontalLayout height="90" padding="0,30,0,0">
 			<Control></Control>
-			<HorizontalLayout bkimage="file='logo_guanwang.png'" width="248" height="57" padding="0,20,0,0"></HorizontalLayout>
+			<HorizontalLayout bkimage="file='logo_guanwang.png'" width="248" height="57" padding="0,0,0,0"></HorizontalLayout>
 			<Control></Control>
 		</HorizontalLayout>
 		
 		<VerticalLayout name="login_input" height="200">
 			<HorizontalLayout height="50">
-				<Label text="账号:" float="true" pos="123,12,228,40"/>
-				<Combo name="accountcombo" float="true" pos="183, 12, 398, 38" tooltip="请点击这里选择您的登录账号" normalimage="file='Setting_Combox_Normal.png' corner='2,2,24,2'" hotimage="file='Setting_Combox_Hover.png' corner='2,2,24,2'" pushedimage="Setting_Combox_Click.png' corner='2,2,24,2'" textpadding="10,1,1,1" >
+				<Label text="账号:" float="true" pos="165,8,228,30"/>
+				<Combo name="accountcombo" float="true" pos="225, 0, 436, 38" tooltip="请点击这里选择您的登录账号" normalimage="file='Login_Combox_Normal.png' corner='2,2,30,2'" hotimage="file='Login_Combox_Hover.png' corner='2,2,30,2'" pushedimage="Login_Combox_Click.png' corner='2,2,30,2'" textpadding="10,1,1,1" >
 				</Combo>
-				<Edit name="accountedit" float="true" pos="183,12,368,38" normalimage="file='Chat_InputBox_BG.png' corner='4,4,4,4'" hotimage="file='Chat_InputBox_BG_Hover.png' corner='4,4,4,4'" />
+				<Edit name="accountedit" float="true" pos="225,0,398,38" normalimage="file='Chat_InputBox_BG.png' corner='4,4,4,4'" hotimage="file='Chat_InputBox_BG_Hover.png' corner='4,4,4,4'" />
 			</HorizontalLayout>
 			
 			<HorizontalLayout height="50">
-				<Control></Control>
-				<Label text="密码:" width="60" />
-				<Edit name="pwdedit" width="215" height="32" password="true" padding="0,12,0,12" normalimage="file='Chat_InputBox_BG.png' corner='4,4,4,4'" hotimage="file='Chat_InputBox_BG_Hover.png' corner='4,4,4,4'" />
-				<Control></Control>
+				<Label text="密码:" float="true" pos="165,8,228,30" />
+				<Edit name="pwdedit" float="true" pos="225,0,436,38" password="true" normalimage="file='Chat_InputBox_BG.png' corner='4,4,4,4'" hotimage="file='Chat_InputBox_BG_Hover.png' corner='4,4,4,4'" />
 			</HorizontalLayout>
 			
 			<HorizontalLayout height="32">
 				<Control></Control>
 				<CheckBox name="login_auto_login" padding="0,7,0,7" width="16" height="16" normalimage="file='Setting_CheckBox_Normal.png'" hotimage="file='Setting_CheckBox_Hover.png'" selectedimage="file='Setting_CheckBox_Click.png'"/>
-				<Label text="自动登录" width="75" padding="10,0,0,0"/>
+				<Label text="自动登录" width="85" padding="10,0,0,0"/>
 				<CheckBox name="login_remember_password" padding="56,7,0,7" width="16" height="16" normalimage="file='Setting_CheckBox_Normal.png'" hotimage="file='Setting_CheckBox_Hover.png'" selectedimage="file='Setting_CheckBox_Click.png'"/>
-				<Label text="记住密码" width="75" padding="10,0,0,0"/>
+				<Label text="记住密码" width="78" padding="10,0,0,0"/>
 				<Control></Control>
 			</HorizontalLayout>
 			
-			<HorizontalLayout height="59">
+			<HorizontalLayout height="68">
 				<Control></Control>
 				<Button name="loginBtn" text="登录" height="44" width="270" padding="0,15,0,0" tooltip="点击这里登录" normalimage="file='btn_border_white.png' corner='5,5,5,5'" hotimage="file='btn_border_white_Hover.png' corner='5,5,5,5'" pushedimage="file='btn_border_white_Click.png' corner='5,5,5,5'" />
 				<Control></Control>
@@ -49,11 +47,11 @@
 		</VerticalLayout>
 		
 		<VerticalLayout name="login_loading" height="200">
-			<Label text="登录中..." align="center" padding="0,120,0,0" font="0"></Label>
+			<Label text="登录中..." align="center" padding="0,100,0,0" font="0"></Label>
 		</VerticalLayout>
 		
 		<VerticalLayout name="login_init_data_ing" height="200">
-			<HorizontalLayout height="150">
+			<HorizontalLayout height="120">
 				<Control></Control>
 				<VerticalLayout width="24" padding="0,80,0,0">
 					<Control></Control>

binární
bin/Win32/Debug/zhipuzi_pos_windows/skin/tab_back.bmp


binární
bin/Win32/Debug/zhipuzi_pos_windows/skin/tab_hot.bmp


binární
bin/Win32/Debug/zhipuzi_pos_windows/skin/tab_normal.bmp


binární
bin/Win32/Debug/zhipuzi_pos_windows/skin/tab_select.bmp


+ 3 - 9
bin/Win32/Debug/zhipuzi_pos_windows/skin/update.xml

@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<Window size="520,410" caption="0,0,0,36" roundcorner="4,4" shadowsize="3" showshadow="true">
+<Window size="600,480" caption="0,0,0,36" roundcorner="4,4" shadowsize="3" showshadow="true">
 	<Font shared="true" id="0" name="微软雅黑" size="20" />
 	<VerticalLayout bkimage="file='Dialog_BG2.png' corner='4,48,4,4'" >		
 		<HorizontalLayout height="44" bkcolor="0xFF3CB371">
@@ -7,9 +7,9 @@
 			<Button name="closebtn" padding="0,13,15,0" width="16" height="16" tooltip="关闭" normalimage="file='close_normal.png'" hotimage="file='close_hover.png'" pushedimage="file='close_normal.png'"/>
 		</HorizontalLayout>
 		
-		<HorizontalLayout height="80">
+		<HorizontalLayout height="90" padding="0,30,0,0">
 			<Control></Control>
-			<HorizontalLayout bkimage="file='logo_guanwang.png'" width="248" height="57" padding="0,18,0,0"></HorizontalLayout>
+			<HorizontalLayout bkimage="file='logo_guanwang.png'" width="248" height="57" padding="0,0,0,0"></HorizontalLayout>
 			<Control></Control>
 		</HorizontalLayout>
 		
@@ -22,11 +22,5 @@
 		</HorizontalLayout>
 		
 		<Label text="正在下载最新版本安装包..." align="center" padding="0,10,0,0"/>
-		
-		<HorizontalLayout padding="0,0,0,15">
-			<Control></Control>
-			<Button name="guanwang" text="{u}www.zhipuzi.com{/u}" showhtml="true" width="200" align="center"/>
-			<Control></Control>
-		</HorizontalLayout>
     </VerticalLayout>
 </Window>

binární
bin/Win32/Debug/zhipuzi_pos_windows/skin/winbk.bmp


binární
dll/debug/DuiLib_d.dll


binární
temp/link/Win32/Debug/DuiLib/DuiLib_d.pdb


+ 20 - 5
zhipuzi_pos_windows/wnd/CLoginWnd.cpp

@@ -81,6 +81,8 @@ void CLoginWnd::Init()
 
 void CLoginWnd::Notify(TNotifyUI& msg)
 {
+	std::wstring senderClassName = msg.pSender->GetClass();
+
     if(msg.sType == _T("click"))
     {
         if(msg.pSender->GetName() == _T("closebtn"))
@@ -139,12 +141,26 @@ void CLoginWnd::Notify(TNotifyUI& msg)
 	}
 	else if (msg.sType == L"windowinit")
 	{
-		m_pm.SetNextTabControl(false);
+		//m_pm.SetNextTabControl(false);
 
-		CEditUI* pAccountEdit = static_cast<CEditUI*>(m_pm.FindControl(_T("accountedit")));
-		if (pAccountEdit)
+		//CEditUI* pAccountEdit = static_cast<CEditUI*>(m_pm.FindControl(_T("accountedit")));
+		//if (pAccountEdit)
+		//{
+			//pAccountEdit->SetFocus();
+		//}
+	}
+	else if (msg.sType == _T("killfocus"))
+	{
+		if (senderClassName == L"EditUI")
+		{
+			CSystem::HideSystemKeyboard();
+		}
+	}
+	else if (msg.sType == _T("setfocus"))
+	{
+		if (senderClassName == L"EditUI")
 		{
-			pAccountEdit->SetFocus();
+			CSystem::ShowSystemKeyboard(m_hWnd);
 		}
 	}
 }
@@ -344,7 +360,6 @@ LRESULT CLoginWnd::MessageHandler(UINT uMsg, WPARAM wParam, LPARAM lParam, bool&
 	else if (uMsg == WM_NEED_UPDATE)
 	{
 		//说明需要升级了
-
 		ShowUpdate();
 
 		return true;