毕业论文论文范文课程设计实践报告法律论文英语论文教学论文医学论文农学论文艺术论文行政论文管理论文计算机安全
您现在的位置: 毕业论文 >> 计算机安全 >> 正文

基于zigbee的无线电子点菜系统 第13页

更新时间:2014-6-28:  来源:毕业论文

基于zigbee的无线电子点菜系统 第13页
static void foods_notif_Add_SJ(HWND hWnd,int id,int nc,DWORD add_data)
{
      int nrow=0,column=0;
      char value[100],*errmsg,**result;  
      SendDlgItemMessage(GetParent(hWnd),Comin_JS_ID,LB_ADDSTRING,0,JS_del);
      sprintf(value,"INSERT INTO t3 VALUES('%s')",JS_del);
       sqlite3_exec(db,value,0,0,errmsg);     
}

 //foods_notif_Comin_SJ
static void   foods_notif_Comin_SJ(HWND hWnd,int id,int nc,DWORD add_data)
{
            if(nc==LBN_CLICKED||nc==LBN_ENTER)
   {       
    
                               int clickn=SendMessage(hWnd,LB_GETCURSEL,0,0L);
     if(clickn>=0)
              {
     char string[50];                  SendMessage(hWnd,LB_GETTEXT,clickn,(LPARAM)JS_del);
     
                                       
    }
                                      
    }      
}
static void  foods_notif_Del_SJ(HWND hWnd,int id,int nc,DWORD add_data)
{
       int nrow=0,ncolumn=0,j=1;
       char value[100],*errmsg,**result;  
     //DELETE FROM  t1 WHERE a='%s' ",del);
     sprintf(value,"DELETE  FROM t3 where jsname='%s'",JS_del);
       sqlite3_exec(db,value,0,0,errmsg);
        SendDlgItemMessage (GetParent(hWnd),Comin_JS_ID, LB_RESETCONTENT, 0, (LPARAM)0);
        sqlite3_get_table(db,"select * from t3",&result,&nrow,&ncolumn,&errmsg);
        for(j;j<(nrow+1)*ncolumn;j++)
         {
                   SendDlgItemMessage(GetParent(hWnd),Comin_JS_ID,LB_ADDSTRING,0,result[j]);      
          }     
        sqlite3_free_table(result);          
     
}
 

//返回主页面
static void   foods_notif_return(HWND hWnd,int id,int nc,DWORD add_data)
{
   }
static int WinProcc(HWND hWnd,int message,WPARAM wParam,LPARAM IParam)
{
   HWND hwnd,hwnd1;
   HDC hdc;
   switch(message)
   {
     
      
     case   MSG_ERASEBKGND:
  {          
      HDC hdc = (HDC)wParam;
      const RECT* clip = (const RECT*)IParam;
      BOOL fGetDC = FALSE;
      RECT rcTemp;
         
    if (hdc == 0) {
      hdc = GetClientDC (hWnd);
      fGetDC = TRUE;
       }      
         
     if (clip) {
      rcTemp = *clip;
      ScreenToClient (hWnd, &rcTemp.left, &rcTemp.top);
      ScreenToClient (hWnd, &rcTemp.right, &rcTemp.bottom);
      IncludeClipRect (hdc, &rcTemp);
        }

        FillBoxWithBitmap (hdc, 0, 0,640, 480, &bmp_bkgnd);
                        if (fGetDC)
                        ReleaseDC (hdc);
   return 0;
           }
      case MSG_CREATE:
      case MSG_TIMER:
      case  MSG_COMMAND:
    switch(wParam)
     {
                      case IDM_EXIT:
            InvalidateRect(hWnd,NULL,TRUE);
                                 show_win(hWnd,0);
                                 initdish(hWnd,"粤        菜",dish_tosec);
     fill_food(hWnd,dish,dish_tosec);                    
    break;
        case IDM_ABOUT:
    show_win(hWnd,1);
                                // calue(hWnd);        
     //MessageBox(hWnd,"已点菜列表^_^","About",MB_OK);
    break;
                    case    IDM_ABOUT1:
    show_win(hWnd,2);
                                InvalidateRect(hWnd,NULL,TRUE);                                     
    MessageBox(hWnd,"酒水","About1",MB_OK); 
                                   break;
                     case   IDM_ABOUT2 :
                                    MessageBox(hWnd,"结帐","About1",MB_OK);
                                    show_win(hWnd,3);
                                     JIEZHANG(hWnd);     
     break;
      
   case  MSG_CLOSE:
      DestroyMainWindow(hWnd);
     PostQuitMessage(hWnd);
    break;
                   }
 /*    case  MSG_PAINT:
       hdc=BeginPaint(hWnd);
    //TextOut(hdc,300,180,"wellcome to here\n");
  
                  EndPaint(hWnd,hdc);
                  break;     */          
        
 default :
  return(DefaultMainWinProc(hWnd,message,wParam,IParam));
   }
   return 0; 
}

int InitMainWindow(void)
{
  
}

int MiniGUIMain(int argc, const char * argv [ ])
{
 
   InitMainWindow();
          ShowWindow(hMainWnd,SW_SHOWNORMAL);
            display(hMainWnd);
   while(GetMessage(&Msg,hMainWnd))
   {
      TranslateMessage(&Msg);
      DispatchMessage(&Msg);
   }
 
       MainWindowThreadCleanup(hMainWnd);
       MiniGUIExtCleanUp ();
      UnloadBitmap (&bmp_bkgnd); 
   return 0;

}
谢  辞
 首先我要感谢北京理工大学珠海学院的嵌入式老师,他们给我提供了开发环境以及开发工具,感谢曾经指导过我的老师,特别是盛老师他给与了我很大的帮助和支持,在遇问题时,盛老师给我解决问题的思路方法,引导我一步步去攻克难题。同时我也要感谢我实习的公司《全视通珠海信息技术有限公司》,在公司里我学到嵌入式开发流程,以及MiniGui界面开发工具的使用.

 << 上一页  [11] [12] [13] 

基于zigbee的无线电子点菜系统 第13页下载如图片无法显示或论文不完整,请联系qq752018766
设为首页 | 联系站长 | 友情链接 | 网站地图 |

copyright©751com.cn 辣文论文网 严禁转载
如果本毕业论文网损害了您的利益或者侵犯了您的权利,请及时联系,我们一定会及时改正。