Changeset 455 in dev for trunk/ab5.0/abdev/ProjectEditor/ProjectEditor.cpp
- Timestamp:
- Mar 22, 2008, 9:47:59 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/ab5.0/abdev/ProjectEditor/ProjectEditor.cpp
r302 r455 86 86 #endif 87 87 88 89 void CreateProcessWithStdHandle( const char *appPath, const char *cmdLine) 90 { 91 std::string argsStr = (std::string)"\"" + appPath + "\" " + cmdLine; 92 STARTUPINFO si; 93 PROCESS_INFORMATION pi; 94 memset(&si,0,sizeof(STARTUPINFO)); 95 si.cb=sizeof(STARTUPINFO); 96 si.dwFlags = STARTF_USESTDHANDLES | STARTF_USESHOWWINDOW; 97 si.wShowWindow = SW_HIDE; 98 si.hStdOutput = GetStdHandle(STD_OUTPUT_HANDLE); 99 si.hStdInput = GetStdHandle(STD_INPUT_HANDLE); 100 si.hStdError = GetStdHandle(STD_ERROR_HANDLE); 101 102 char args[8192]; 103 lstrcpy( args, argsStr.c_str() ); 104 105 CreateProcess( NULL, args, NULL, NULL, FALSE, NORMAL_PRIORITY_CLASS, NULL, NULL, &si, &pi ); 106 } 88 107 89 108 void ToBigChar(char str[]){ … … 1288 1307 1289 1308 int width_SideWeb=0; 1290 if(pobj_SideWeb->bShow){ 1291 width_SideWeb=pobj_nv->width_WebSearchView+LEVER_THICK; 1309 if( pobj_SideWeb ) 1310 { 1311 if(pobj_SideWeb->bShow){ 1312 width_SideWeb=pobj_nv->width_WebSearchView+LEVER_THICK; 1313 } 1292 1314 } 1293 1315 … … 1323 1345 1); 1324 1346 1325 if(pobj_SideWeb->bShow){ 1326 //SideWeb 1327 pobj_SideWeb->resize( 1328 width_owner - pobj_nv->width_WebSearchView, 1329 height_Rebar, 1330 pobj_nv->width_WebSearchView, 1331 height_MdiClient); 1332 } 1333 else pobj_SideWeb->resize(0,0,0,0); 1347 if( pobj_SideWeb ) 1348 { 1349 if(pobj_SideWeb->bShow){ 1350 //SideWeb 1351 pobj_SideWeb->resize( 1352 width_owner - pobj_nv->width_WebSearchView, 1353 height_Rebar, 1354 pobj_nv->width_WebSearchView, 1355 height_MdiClient); 1356 } 1357 else pobj_SideWeb->resize(0,0,0,0); 1358 } 1334 1359 1335 1360 if(width_pjv){ … … 1459 1484 1460 1485 case WM_DRAWITEM: 1461 DRAWITEMSTRUCT *pdis; 1462 pdis=(DRAWITEMSTRUCT *)lParam; 1463 1464 if(pdis->CtlType==ODT_MENU){ 1465 if(!pobj_MainMenu) return 0; 1466 1467 CMenuItemData *pobj_MenuItemData; 1468 pobj_MenuItemData=(CMenuItemData *)pdis->itemData; 1469 if(pobj_MainMenu->hMenu==pobj_MenuItemData->pobj_ThisMenu->hMenu){ 1470 //メインメニューの親アイテム 1471 pobj_MainMenu->OwnerDrawMenu(pdis->hDC, 1472 &pdis->rcItem, 1473 (pdis->itemState&ODS_SELECTED)!=0, 1474 pobj_MenuItemData->item_index); 1486 { 1487 DRAWITEMSTRUCT *pdis = (DRAWITEMSTRUCT *)lParam; 1488 1489 if(pdis->CtlType==ODT_MENU){ 1490 if(!pobj_MainMenu) return 0; 1491 1492 CMenuItemData *pobj_MenuItemData; 1493 pobj_MenuItemData=(CMenuItemData *)pdis->itemData; 1494 if(pobj_MainMenu->hMenu==pobj_MenuItemData->pobj_ThisMenu->hMenu){ 1495 //メインメニューの親アイテム 1496 pobj_MainMenu->OwnerDrawMenu(pdis->hDC, 1497 &pdis->rcItem, 1498 (pdis->itemState&ODS_SELECTED)!=0, 1499 pobj_MenuItemData->item_index); 1500 } 1501 else{ 1502 //メインメニューにぶらさがるサブメニュー 1503 pobj_MainMenu->OwnerDrawSubMenu(pobj_MenuItemData->pobj_ThisMenu->hMenu, 1504 pdis->hDC, 1505 &pdis->rcItem, 1506 (pdis->itemState&ODS_SELECTED)!=0, 1507 pobj_MenuItemData->item_index); 1508 } 1475 1509 } 1476 else{ 1477 //メインメニューにぶらさがるサブメニュー 1478 pobj_MainMenu->OwnerDrawSubMenu(pobj_MenuItemData->pobj_ThisMenu->hMenu, 1479 pdis->hDC, 1480 &pdis->rcItem, 1481 (pdis->itemState&ODS_SELECTED)!=0, 1482 pobj_MenuItemData->item_index); 1483 } 1484 } 1485 return 0; 1510 1511 return 0; 1512 } 1486 1513 1487 1514 case WM_NOTIFY: … … 2054 2081 2055 2082 sprintf(str,"%s%s",pj_editor_Dir,lpszCompilerName); 2056 ShellExecute(hwnd,"open",str,temporary,NULL,SW_SHOWNORMAL); 2083 2084 CreateProcessWithStdHandle( str, temporary ); 2085 2057 2086 return 0; 2058 2087 case IDM_DEBUGCOMPILE: … … 2104 2133 2105 2134 sprintf(str,"%s%s",pj_editor_Dir,lpszCompilerName); 2106 ShellExecute(hwnd,"open",str,temporary,NULL,SW_SHOWNORMAL); 2135 2136 CreateProcessWithStdHandle( str, temporary ); 2107 2137 2108 2138 return 0; … … 2140 2170 sprintf(str,"%s%s",pj_editor_Dir,WIN64_COMPILER_NAME); 2141 2171 2142 ShellExecute(hwnd,"open",str,temporary,NULL,SW_SHOWNORMAL); 2172 CreateProcessWithStdHandle( str, temporary ); 2173 2143 2174 return 0; 2144 2175 case IDM_RELEASECOMPILE: … … 2190 2221 2191 2222 sprintf(str,"%s%s",pj_editor_Dir,lpszCompilerName); 2192 ShellExecute(hwnd,"open",str,temporary,NULL,SW_SHOWNORMAL); 2223 2224 CreateProcessWithStdHandle( str, temporary ); 2225 2193 2226 return 0; 2194 2227 case IDM_RELEASERUN: … … 2721 2754 } 2722 2755 #endif 2723 if(pobj_SideWeb->bShow){ 2724 //SideWebとMDIクライアントの境目のサイズ変更ライン 2725 pobj_SideWeb->GetRect(&rect); 2726 ClientToScreen(hwnd,&rect); 2727 if(rect.top<=pos.y&&pos.y<=rect.bottom&& 2728 rect.left-LEVER_THICK<=pos.x&&pos.x<=rect.left){ 2729 SetCursor(LoadCursor(0,IDC_SIZEWE)); 2756 if( pobj_SideWeb ) 2757 { 2758 if(pobj_SideWeb->bShow){ 2759 //SideWebとMDIクライアントの境目のサイズ変更ライン 2760 pobj_SideWeb->GetRect(&rect); 2761 ClientToScreen(hwnd,&rect); 2762 if(rect.top<=pos.y&&pos.y<=rect.bottom&& 2763 rect.left-LEVER_THICK<=pos.x&&pos.x<=rect.left){ 2764 SetCursor(LoadCursor(0,IDC_SIZEWE)); 2765 } 2730 2766 } 2731 2767 }
Note:
See TracChangeset
for help on using the changeset viewer.