浏览代码

完成toast

zhangyang 4 年之前
父节点
当前提交
f6319bc51c

+ 7 - 4
bin/Win32/Debug/zhipuzi_pos_windows/skin/diandan_fooditem.xml

@@ -1,10 +1,13 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <Window>
-	<Font id="diandan_price" name="微软雅黑" size="20" />
+	<Font id="diandan_price" name="微软雅黑" size="18" />
+	<Font id="1" name="微软雅黑" size="14" />
 	
 	<DiandanFoodItem name="diandan_fooditem" bkcolor="#FFFFFFFF" padding="0,0,7,7">
-		<Control name="image" height="135" bkimage="file='food_image_default.png'" padding="0,0,0,0"></Control>
-		<Label name="foodname" width="135" height="40" multiline="true" endellipsis="true"></Label>
-		<Label name="price" height="30" font="daindan_price" textcolor="#FFFF7F50" align="right"></Label>
+		<Control name="image" height="165" bkimage="file='food_image_default.png'" padding="0,0,0,0"></Control>
+		<Label name="foodname" width="165" height="60" multiline="true" endellipsis="true"></Label>
+		<Label name="price" height="30" font="daindan_price" textcolor="#FFFF7F50" align="left"></Label>
+		<Label name="nature" visible="false" width="50" height="26" font="1" text="多属性" float="true" pos="110,224,160,250" textcolor="#FFFFFFFF" bkcolor="#FF2E8B57" align="center"></Label>		
+		<Label name="chengzhong" visible="false" width="50" height="26" font="1" text="称重" float="true" pos="110,224,160,250" textcolor="#FFFFFFFF" bkcolor="#FFFF4500" align="center"></Label>
 	</DiandanFoodItem>
 </Window>

+ 10 - 10
bin/Win32/Debug/zhipuzi_pos_windows/skin/diandan_page.xml

@@ -45,17 +45,17 @@
 					<Control width="1" bkcolor="#FFEBE8E8"></Control>
 					
 					<VerticalLayout width="120" padding="0,0,0,0">
-						<Button name="btn_diandan_jia" width="80" height="36" padding="10,80,10,0" text="+" textcolor="#FFFFFFFF" />
-						<Button name="btn_diandan_jian" width="80" height="36" padding="10,15,10,0" text="-" textcolor="#FFFFFFFF" />
-						<Button name="btn_diandan_shanchu" width="80" height="36" padding="10,15,10,0" text="删除" textcolor="#FFFFFFFF" />
-						<Button name="btn_diandan_guige" width="80" height="36" padding="10,15,10,0" text="规格/做法" textcolor="#FFFFFFFF" />
+						<Button name="btn_diandan_jia" width="90" height="38" padding="15,80,15,0" text="+" normalimage="file='Btn_White.png' corner='5,5,5,5'" hotimage="file='Btn_White_Hover.png' corner='5,5,5,5'" pushedimage="file='Btn_White_Click.png' corner='5,5,5,5'" />
+						<Button name="btn_diandan_jian" width="90" height="38" padding="15,15,15,0" text="-" normalimage="file='Btn_White.png' corner='5,5,5,5'" hotimage="file='Btn_White_Hover.png' corner='5,5,5,5'" pushedimage="file='Btn_White_Click.png' corner='5,5,5,5'" />
+						<Button name="btn_diandan_shanchu" width="90" height="38" padding="15,15,15,0" text="删除" normalimage="file='Btn_White.png' corner='5,5,5,5'" hotimage="file='Btn_White_Hover.png' corner='5,5,5,5'" pushedimage="file='Btn_White_Click.png' corner='5,5,5,5'" />
+						<Button name="btn_diandan_guige" width="90" height="38" padding="15,30,15,0" text="规格/做法" normalimage="file='Btn_White.png' corner='5,5,5,5'" hotimage="file='Btn_White_Hover.png' corner='5,5,5,5'" pushedimage="file='Btn_White_Click.png' corner='5,5,5,5'" />
 						
-						<Button name="btn_diandan_dabao" width="80" height="36" padding="10,50,10,0" text="打包" textcolor="#FFFFFFFF" />
+						<Button name="btn_diandan_dabao" width="90" height="38" padding="15,15,15,0" text="打包" normalimage="file='Btn_White.png' corner='5,5,5,5'" hotimage="file='Btn_White_Hover.png' corner='5,5,5,5'" pushedimage="file='Btn_White_Click.png' corner='5,5,5,5'" />
 						
-						<Button name="btn_diandan_cundan" width="80" height="36" padding="10,50,10,0" text="存单" textcolor="#FFFFFFFF" />
-						<Button name="btn_diandan_qudan" width="80" height="36" padding="10,15,10,0" text="取单" textcolor="#FFFFFFFF" />
+						<Button name="btn_diandan_cundan" width="90" height="38" padding="15,50,15,0" text="存单" normalimage="file='Btn_White.png' corner='5,5,5,5'" hotimage="file='Btn_White_Hover.png' corner='5,5,5,5'" pushedimage="file='Btn_White_Click.png' corner='5,5,5,5'" />
+						<Button name="btn_diandan_qudan" width="90" height="38" padding="15,15,15,0" text="取单" normalimage="file='Btn_White.png' corner='5,5,5,5'" hotimage="file='Btn_White_Hover.png' corner='5,5,5,5'" pushedimage="file='Btn_White_Click.png' corner='5,5,5,5'" />
 						
-						<Button name="btn_diandan_zhengdanbeizhu" width="80" height="36" padding="10,50,10,0" text="整单备注" textcolor="#FFFFFFFF" />
+						<Button name="btn_diandan_zhengdanbeizhu" width="90" height="38" padding="15,15,15,0" text="整单备注" normalimage="file='Btn_White.png' corner='5,5,5,5'" hotimage="file='Btn_White_Hover.png' corner='5,5,5,5'" pushedimage="file='Btn_White_Click.png' corner='5,5,5,5'" />
 					</VerticalLayout>
 				</HorizontalLayout>
 				
@@ -92,11 +92,11 @@
 			<Control width="1" bkcolor="#FFEBE8E8"></Control>
 			
 			<VerticalLayout name="diandan_food_layout">
-				<HorizontalLayout name="diandan_fenlei_layout" height="62" hscrollbar="true" padding="15,15,15,0">
+				<HorizontalLayout name="diandan_fenlei_layout" height="80" hscrollbar="true" padding="0,0,0,0" bkcolor="#FFFFFFFF">
 
 				</HorizontalLayout>
 				
-				<TileLayout name="diandan_foodlist" padding="15,15,15,0" childpadding="1" itemsize="150,220" vscrollbar="true" hscrollbar="false">
+				<TileLayout name="diandan_foodlist" padding="0,0,0,0" inset="15,15,15,15" childpadding="1" itemsize="180,270" vscrollbar="true" hscrollbar="false">
 				
 				</TileLayout>
 				

+ 1 - 1
bin/Win32/Debug/zhipuzi_pos_windows/skin/foodtype_option.xml

@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <Window>
-	<FoodtypeOption endellipsis="true" align="center" valign="center" width="120" height="44" padding="0,0,15,0" bkcolor="#FFFFFFFF" selectedtextcolor="FFFF0000">
+	<FoodtypeOption endellipsis="true" align="center" valign="center" width="120" height="42" padding="15,19,0,0" bkcolor="#FFECECEC" selectedtextcolor="#FF3CB371">
 	</FoodtypeOption>
 </Window>

+ 1 - 1
bin/Win32/Debug/zhipuzi_pos_windows/skin/main.xml

@@ -9,7 +9,7 @@
 	
 	<Default name="Button" value="normalimage=&quot;file='Btn_Green.png' corner='5,5,5,5'&quot; hotimage=&quot;file='Btn_Green_Hover.png' corner='5,5,5,5'&quot; pushedimage=&quot;file='Btn_Green_Click.png' corner='5,5,5,5'&quot; " />	
 
-	<VerticalLayout bkcolor="#FFEFF6EE">
+	<VerticalLayout bkcolor="#FFF5F5F5">
 		<HorizontalLayout height="79" bkcolor="#FF3CB371">
 			<Control bkimage="main_logo.png" width="179" height="46" padding="15,17,0,17"></Control>
 			<Control width="1" padding="20,27,15,20" bkcolor="#FFFFFFFF"></Control>

+ 7 - 0
bin/Win32/Debug/zhipuzi_pos_windows/skin/toast_wnd.xml

@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<Window size="380,44" alpha="100" layeredimage="file='value_bkg.png' corner='5,5,5,5'" layeredopacity="255">
+	<Font id="1" name="微软雅黑" size="18" />
+	<VerticalLayout bkcolor="#33000000">
+		<Label name="value_info" float="true" text="" textcolor="#FFFFFFFF" font="1" width="380" height="44" align="center"/>
+	</VerticalLayout>
+</Window>

二进制
bin/Win32/Debug/zhipuzi_pos_windows/skin/value_bkg.png


+ 20 - 0
zhipuzi_pos_windows/control/CDiandanFoodItemUI.cpp

@@ -88,6 +88,10 @@ void CDiandanFoodItemUI::UpdateShow()
 		wstring price = L"¥" + CLewaimaiString::UTF8ToUnicode(m_foodpackageinfo.price);
 
 		pPrice->SetText(price.c_str());
+
+		//属性商品,显示多属性标签
+		CLabelUI* pNature = static_cast<CLabelUI*>(this->FindSubControl(_T("nature")));
+		pNature->SetVisible(true);
 	}
 	else
 	{
@@ -113,5 +117,21 @@ void CDiandanFoodItemUI::UpdateShow()
 		}
 
 		pPrice->SetText(price.c_str());
+
+		if (m_foodinfo.is_weight == "1")
+		{
+			//称重商品,显示称重的标签
+			CLabelUI* pChenzhong = static_cast<CLabelUI*>(this->FindSubControl(_T("chengzhong")));
+			pChenzhong->SetVisible(true);
+		}
+		else
+		{
+			if (m_foodinfo.is_nature == "1")
+			{
+				//属性商品,显示多属性标签
+				CLabelUI* pNature = static_cast<CLabelUI*>(this->FindSubControl(_T("nature")));
+				pNature->SetVisible(true);
+			}
+		}
 	}
 }

+ 49 - 13
zhipuzi_pos_windows/page/CDiandanPageUI.cpp

@@ -340,6 +340,9 @@ void CDiandanPageUI::InitJiesuanInfo()
 	//调整区域高度
 	int lastRow = (num -  1) / 3 + 1;
 	pZhifufangshiLayout->SetFixedHeight(lastRow * 105);
+
+	//默认展示选购页面
+	ShowXuangouPage();
 }
 
 //处理按钮点击类事件
@@ -1294,6 +1297,46 @@ void CDiandanPageUI::UpdateJiesuanInfo()
 	pYingshou->SetText((L"应收金额:" + CLewaimaiString::UTF8ToUnicode(CLewaimaiString::DoubleToString(cur_price, 2)) + L"元").c_str());
 }
 
+//展示结算页面,隐藏选购页面
+void CDiandanPageUI::ShowJiesuanPage()
+{
+	//先隐藏商品页面
+	CVerticalLayoutUI* pFoodLayout = static_cast<CVerticalLayoutUI*>(this->FindSubControl(_T("diandan_food_layout")));
+	pFoodLayout->SetVisible(false);
+
+	//隐藏结算按钮
+	CHorizontalLayoutUI* pPayLayout = static_cast<CHorizontalLayoutUI*>(this->FindSubControl(_T("diandan_pay_layout")));
+	pPayLayout->SetVisible(false);
+
+	//再展示结算页面
+	CHorizontalLayoutUI* pJiesuanLayout = static_cast<CHorizontalLayoutUI*>(this->FindSubControl(_T("diandan_jiesuan_layout")));
+	pJiesuanLayout->SetVisible(true);
+
+	//展示继续加菜的按钮
+	CButtonUI* pJiacaiBtn = static_cast<CButtonUI*>(this->FindSubControl(_T("btn_diandan_jixujiacai")));
+	pJiacaiBtn->SetVisible(true);
+}
+
+//展示选购页面,隐藏结算页面
+void CDiandanPageUI::ShowXuangouPage()
+{
+	//先展示商品页面
+	CVerticalLayoutUI* pFoodLayout = static_cast<CVerticalLayoutUI*>(this->FindSubControl(_T("diandan_food_layout")));
+	pFoodLayout->SetVisible(true);
+
+	//展示结算按钮
+	CHorizontalLayoutUI* pPayLayout = static_cast<CHorizontalLayoutUI*>(this->FindSubControl(_T("diandan_pay_layout")));
+	pPayLayout->SetVisible(true);
+
+	//再隐藏结算页面
+	CHorizontalLayoutUI* pJiesuanLayout = static_cast<CHorizontalLayoutUI*>(this->FindSubControl(_T("diandan_jiesuan_layout")));
+	pJiesuanLayout->SetVisible(false);
+
+	//隐藏继续加菜的按钮
+	CButtonUI* pJiacaiBtn = static_cast<CButtonUI*>(this->FindSubControl(_T("btn_diandan_jixujiacai")));
+	pJiacaiBtn->SetVisible(false);
+}
+
 void CDiandanPageUI::ClickFoodAction()
 {
 	bool is_taocan = m_cur_click_food_item->GetIsTaocan();
@@ -1664,21 +1707,14 @@ void CDiandanPageUI::ClickZhengdanMemo()
 
 void CDiandanPageUI::ClickGengduoPay()
 {
-	//先隐藏商品页面
-	CVerticalLayoutUI* pFoodLayout = static_cast<CVerticalLayoutUI*>(this->FindSubControl(_T("diandan_food_layout")));
-	pFoodLayout->SetVisible(false);
-
-	//隐藏结算按钮
-	CHorizontalLayoutUI* pPayLayout = static_cast<CHorizontalLayoutUI*>(this->FindSubControl(_T("diandan_pay_layout")));
-	pPayLayout->SetVisible(false);
+	if (m_cur_diandan_order.getItemNum() == 0)
+	{
+		m_pMainWnd->ShowToast(L"请先选择商品再结算");
 
-	//再展示结算页面
-	CHorizontalLayoutUI* pJiesuanLayout = static_cast<CHorizontalLayoutUI*>(this->FindSubControl(_T("diandan_jiesuan_layout")));
-	pJiesuanLayout->SetVisible(true);
+		return;
+	}
 
-	//展示继续加菜的按钮
-	CButtonUI* pJiacaiBtn = static_cast<CButtonUI*>(this->FindSubControl(_T("btn_diandan_jixujiacai")));
-	pJiacaiBtn->SetVisible(true);
+	ShowJiesuanPage();
 }
 
 void CDiandanPageUI::JixuJiacai()

+ 6 - 0
zhipuzi_pos_windows/page/CDiandanPageUI.h

@@ -54,6 +54,12 @@ public:
 	//任何可以引起价格变化的,比如添加、修改、删除商品,或者修改优惠等,需要重新计算总价格,刷新结算账单等地方的显示,都要调用这个方法
 	void UpdateJiesuanInfo();
 
+	//展示结算页面,隐藏选购页面
+	void ShowJiesuanPage();
+
+	//展示选购页面,隐藏结算页面
+	void ShowXuangouPage();
+
 	//点击某一个商品的item之后的处理逻辑
 	void ClickFoodAction();
 

+ 18 - 0
zhipuzi_pos_windows/wnd/CMainWnd.cpp

@@ -9,6 +9,8 @@
 
 #include <urlmon.h>
 
+#include "../wnd/CToastWnd.h"
+
 void CMainWnd::Init()
 {
 	//设置店铺名字
@@ -718,3 +720,19 @@ void CMainWnd::SetInfopageWaimaiorderParam(std::string order_id, std::string ord
 	m_infopage_waimaiorder_id = order_id;
 	m_infopage_waimaiorder_no = order_no;
 }
+
+void CMainWnd::ShowToast(std::wstring toast_value)
+{
+	CToastWnd* pYouhuiDlg = new CToastWnd();
+
+	if (pYouhuiDlg != NULL)
+	{
+		pYouhuiDlg->Create(m_pm.GetPaintWindow(), _T(""), UI_WNDSTYLE_DIALOG, WS_EX_WINDOWEDGE);
+		pYouhuiDlg->SetIcon(IDI_ICON_DUILIB);
+		pYouhuiDlg->CenterWindow();
+
+		pYouhuiDlg->SetToast(toast_value);
+
+		pYouhuiDlg->ShowWindow();
+	}
+}

+ 2 - 0
zhipuzi_pos_windows/wnd/CMainWnd.h

@@ -96,6 +96,8 @@ public:
 
 	void SetInfopageWaimaiorderParam(std::string order_id, std::string order_no);
 
+	void ShowToast(std::wstring toast_value);
+
 public:
     CPaintManagerUI m_pm;
 

+ 171 - 0
zhipuzi_pos_windows/wnd/CToastWnd.cpp

@@ -0,0 +1,171 @@
+#include "../pch/pch.h"
+#include "CToastWnd.h"
+
+#define WM_TIMER_WND_CLOSE 200001
+
+LRESULT CToastWnd::OnNcHitTest(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
+{
+	POINT pt;
+	pt.x = GET_X_LPARAM(lParam);
+	pt.y = GET_Y_LPARAM(lParam);
+	::ScreenToClient(*this, &pt);
+
+	RECT rcClient;
+	::GetClientRect(*this, &rcClient);
+
+	RECT rcCaption = m_pm.GetCaptionRect();
+	if (pt.x >= rcClient.left + rcCaption.left && pt.x < rcClient.right - rcCaption.right \
+		&& pt.y >= rcCaption.top && pt.y < rcCaption.bottom)
+	{
+		CControlUI* pControl = static_cast<CControlUI*>(m_pm.FindControl(pt));
+		if (pControl && _tcscmp(pControl->GetClass(), DUI_CTR_BUTTON) != 0)
+		{
+			return HTCAPTION;
+		}
+	}
+
+	return HTCLIENT;
+}
+
+LRESULT CToastWnd::OnSize(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
+{
+	SIZE szRoundCorner = m_pm.GetRoundCorner();
+	if (!::IsIconic(*this) && (szRoundCorner.cx != 0 || szRoundCorner.cy != 0))
+	{
+		CDuiRect rcWnd;
+		::GetWindowRect(*this, &rcWnd);
+		rcWnd.Offset(-rcWnd.left, -rcWnd.top);
+		rcWnd.right++;
+		rcWnd.bottom++;
+		HRGN hRgn = ::CreateRoundRectRgn(rcWnd.left, rcWnd.top, rcWnd.right, rcWnd.bottom, szRoundCorner.cx, szRoundCorner.cy);
+		::SetWindowRgn(*this, hRgn, TRUE);
+		::DeleteObject(hRgn);
+	}
+
+	bHandled = FALSE;
+	return 0;
+}
+LRESULT CToastWnd::OnTimer(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
+{
+	if (wParam != WM_TIMER_WND_CLOSE)
+	{
+		bHandled = FALSE;
+		return 0;
+	}
+
+	Close();
+
+	bHandled = TRUE;
+
+	return 0;
+}
+
+LRESULT CToastWnd::HandleMessage(UINT uMsg, WPARAM wParam, LPARAM lParam)
+{
+	LRESULT lRes = 0;
+	BOOL bHandled = TRUE;
+	switch (uMsg)
+	{
+	case WM_CREATE:
+		lRes = OnCreate(uMsg, wParam, lParam, bHandled);
+		break;
+	case WM_NCACTIVATE:
+		lRes = OnNcActivate(uMsg, wParam, lParam, bHandled);
+		break;
+	case WM_NCCALCSIZE:
+		lRes = OnNcCalcSize(uMsg, wParam, lParam, bHandled);
+		break;
+	case WM_NCPAINT:
+		lRes = OnNcPaint(uMsg, wParam, lParam, bHandled);
+		break;
+	case WM_NCHITTEST:
+		lRes = OnNcHitTest(uMsg, wParam, lParam, bHandled);
+		break;
+	case WM_SIZE:
+		lRes = OnSize(uMsg, wParam, lParam, bHandled);
+		break;
+	case WM_TIMER:
+		lRes = OnTimer(uMsg, wParam, lParam, bHandled);
+		break;
+	default:
+		bHandled = FALSE;
+	}
+	if (bHandled)
+	{
+		return lRes;
+	}
+	if (m_pm.MessageHandler(uMsg, wParam, lParam, lRes))
+	{
+		return lRes;
+	}
+	return CWindowWnd::HandleMessage(uMsg, wParam, lParam);
+}
+
+LRESULT CToastWnd::MessageHandler(UINT uMsg, WPARAM wParam, LPARAM lParam, bool& bHandled)
+{
+	if (uMsg == WM_KEYDOWN)
+	{
+		if (wParam == VK_RETURN)
+		{
+			return true;
+		}
+		else if (wParam == VK_ESCAPE)
+		{
+			return true;
+		}
+	}
+
+	return false;
+}
+
+LRESULT CToastWnd::OnCreate(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
+{
+	LONG styleValue = ::GetWindowLong(*this, GWL_STYLE);
+	styleValue &= ~WS_CAPTION;
+	::SetWindowLong(*this, GWL_STYLE, styleValue | WS_CLIPSIBLINGS | WS_CLIPCHILDREN);
+
+	// 把自己的窗口句柄与窗口绘制管理器挂接在一起
+	m_pm.Init(m_hWnd);
+
+	m_pm.AddPreMessageFilter(this);
+
+	CDialogBuilder builder;
+
+	CControlUI* pRoot = builder.Create(_T("toast_wnd.xml"), (UINT)0, NULL, &m_pm);
+	ASSERT(pRoot && "Failed to parse XML");
+
+	// 把这些控件绘制到本窗口上
+	m_pm.AttachDialog(pRoot);
+
+	// 把自己加入到CPaintManagerUI的m_aNotifiers数组中,用于处理Notify函数
+	m_pm.AddNotifier(this);
+
+	Init();
+
+	return 0;
+}
+
+void CToastWnd::Notify(TNotifyUI& msg)
+{
+	if (msg.sType == _T("click"))
+	{
+		DuiLib::CDuiString senderName = msg.pSender->GetName();
+
+		if (senderName == _T("quit"))
+		{
+			Close(IDCANCEL);
+			return;
+		}
+	}
+}
+
+void CToastWnd::Init()
+{
+	SetTimer(m_hWnd, WM_TIMER_WND_CLOSE, 2000, NULL);
+}
+
+void CToastWnd::SetToast(std::wstring toast)
+{
+	CLabelUI* pLabel = static_cast<CLabelUI*>(m_pm.FindControl(_T("value_info")));
+	pLabel->SetText(toast.c_str());
+}

+ 67 - 0
zhipuzi_pos_windows/wnd/CToastWnd.h

@@ -0,0 +1,67 @@
+#pragma once
+
+#include "../pch/pch.h"
+#include "CMainWnd.h"
+
+class CToastWnd : public CWindowWnd, public INotifyUI, public IMessageFilterUI
+{
+public:
+	LPCTSTR GetWindowClassName() const
+	{
+		return _T("UIMemoWndFrame");
+	};
+
+	UINT GetClassStyle() const
+	{
+		return UI_CLASSSTYLE_DIALOG;
+	};
+
+	void OnFinalMessage(HWND /*hWnd*/)
+	{
+		//WindowImplBase::OnFinalMessage(hWnd);
+		m_pm.RemovePreMessageFilter(this);
+
+		//delete this;
+	};
+
+	void Init();
+
+	void SetToast(std::wstring toast);
+
+	void Notify(TNotifyUI& msg);
+
+	LRESULT OnCreate(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
+
+	LRESULT OnNcActivate(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
+	{
+		if (::IsIconic(*this))
+		{
+			bHandled = FALSE;
+		}
+		return (wParam == 0) ? TRUE : FALSE;
+	}
+
+	LRESULT OnNcCalcSize(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
+	{
+		return 0;
+	}
+
+	LRESULT OnNcPaint(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
+	{
+		return 0;
+	}
+
+	LRESULT OnNcHitTest(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
+
+	LRESULT OnSize(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
+
+	LRESULT OnTimer(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
+
+	LRESULT HandleMessage(UINT uMsg, WPARAM wParam, LPARAM lParam);
+
+	LRESULT MessageHandler(UINT uMsg, WPARAM wParam, LPARAM lParam, bool& bHandled);
+
+public:
+	CPaintManagerUI m_pm;
+};
+

+ 2 - 0
zhipuzi_pos_windows/zhipuzi_pos_windows.vcxproj

@@ -225,6 +225,7 @@ copy $(ProjectDir)conf\ $(SolutionDir)bin\$(Platform)\$(Configuration)\conf\</Co
     </PostBuildEvent>
   </ItemDefinitionGroup>
   <ItemGroup>
+    <ClInclude Include="wnd\CToastWnd.h" />
     <ClInclude Include="wnd\CFulikaShoukuanWnd.h" />
     <ClInclude Include="wnd\CXianjinShoukuanWnd.h" />
     <ClInclude Include="wnd\CHuiyuanShoukuanWnd.h" />
@@ -288,6 +289,7 @@ copy $(ProjectDir)conf\ $(SolutionDir)bin\$(Platform)\$(Configuration)\conf\</Co
     <ClInclude Include="helper\CSystem.h" />
   </ItemGroup>
   <ItemGroup>
+    <ClCompile Include="wnd\CToastWnd.cpp" />
     <ClCompile Include="wnd\CFulikaShoukuanWnd.cpp" />
     <ClCompile Include="wnd\CXianjinShoukuanWnd.cpp" />
     <ClCompile Include="wnd\CHuiyuanShoukuanWnd.cpp" />

+ 6 - 0
zhipuzi_pos_windows/zhipuzi_pos_windows.vcxproj.filters

@@ -198,6 +198,9 @@
     <ClInclude Include="wnd\CFulikaShoukuanWnd.h">
       <Filter>头文件</Filter>
     </ClInclude>
+    <ClInclude Include="wnd\CToastWnd.h">
+      <Filter>头文件</Filter>
+    </ClInclude>
   </ItemGroup>
   <ItemGroup>
     <ClCompile Include="pch\pch.cpp">
@@ -359,6 +362,9 @@
     <ClCompile Include="wnd\CFulikaShoukuanWnd.cpp">
       <Filter>源文件</Filter>
     </ClCompile>
+    <ClCompile Include="wnd\CToastWnd.cpp">
+      <Filter>源文件</Filter>
+    </ClCompile>
   </ItemGroup>
   <ItemGroup>
     <Image Include="resource\zhipuzi.ico">