Changeset 407
- Timestamp:
- Apr 19, 2010, 8:10:49 PM (15 years ago)
- Location:
- trunk/Lucide/gui
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
TabularUnified trunk/Lucide/gui/Lucide.rc ¶
r406 r407 160 160 END 161 161 162 ACCELTABLE IDA_FONTSINFOACCEL 163 BEGIN 164 "C", CM_COPY, CONTROL 165 "c", CM_COPY, CONTROL 166 "/", CM_SELECTALL, CONTROL 167 "A", CM_SELECTALL, CONTROL 168 "a", CM_SELECTALL, CONTROL 169 VK_INSERT, CM_COPY, VIRTUALKEY, CONTROL 170 END 171 162 172 rcinclude dialogs.rc 163 173 -
TabularUnified trunk/Lucide/gui/Lucide_res.H ¶
r406 r407 62 62 #define IDA_MAINACCEL 101 63 63 #define IDA_DOCINFOACCEL 102 64 #define IDA_FONTSINFOACCEL 103 64 65 65 66 #define CM_NEW_WINDOW 101 -
TabularUnified trunk/Lucide/gui/dialogs.rc ¶
r406 r407 19 19 DIALOG "FONTINFO_FONTINFO", 100, 6, 52, 348, 112, WS_VISIBLE, FCF_TITLEBAR 20 20 BEGIN 21 CONTROL "", IDC_FONTSLIST, 2, 26, 344, 84, WC_CONTAINER, CCS_MINIRECORDCORE | CCS_MINIICONS | CCS_READONLY | CCS_ SINGLESEL | WS_VISIBLE | WS_GROUP | WS_TABSTOP21 CONTROL "", IDC_FONTSLIST, 2, 26, 344, 84, WC_CONTAINER, CCS_MINIRECORDCORE | CCS_MINIICONS | CCS_READONLY | CCS_EXTENDSEL | WS_VISIBLE | WS_GROUP | WS_TABSTOP 22 22 PRESPARAMS PP_FONTNAMESIZE "9.WarpSans" 23 23 DEFPUSHBUTTON "FONTINFO_CLOSE", DID_OK, 282, 4, 57, 14, BS_PUSHBUTTON | BS_DEFAULT | WS_VISIBLE | WS_DISABLED | WS_TABSTOP -
TabularUnified trunk/Lucide/gui/fontsInfoDlg.cpp ¶
r367 r407 44 44 #include "Lucide_res.h" 45 45 #include "messages.h" 46 #include "cpconv.h" 46 47 47 48 … … 150 151 } 151 152 153 static bool addPropToString( HWND hwndCntr, PRECORDCORE pRec, void *pUser ) 154 { 155 ListRec *rec = reinterpret_cast<ListRec *>( pRec ); 156 std::string *str = static_cast<std::string *>( pUser ); 157 if ( !str->empty() ) 158 *str += '\n'; 159 *str += rec->miniRecordCore.pszIcon; 160 *str += " | "; 161 *str += rec->type; 162 *str += " | "; 163 *str += rec->embed; 164 return true; 165 } 166 167 static bool selectProp( HWND hwndCntr, PRECORDCORE pRec, void *pUser ) 168 { 169 ListRec *rec = reinterpret_cast<ListRec *>( pRec ); 170 return WinSendMsg( hwndCntr, CM_SETRECORDEMPHASIS, 171 MPFROMP( &rec->miniRecordCore ), 172 MPFROM2SHORT( TRUE, CRA_SELECTED ) ) == (MRESULT)TRUE; 173 } 174 152 175 MRESULT EXPENTRY FontsInfoDlg::fontsInfoDlgProc( HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2 ) 153 176 { … … 172 195 localizeDialog( hwnd ); 173 196 centerWindow( _this->hFrame, hwnd ); 197 198 // setup the accelerators 199 WinSetAccelTable( hab, WinLoadAccelTable( hab, _hmod, IDA_FONTSINFOACCEL ), hwnd ); 174 200 175 201 // init container … … 234 260 break; 235 261 262 case WM_COMMAND: 263 { 264 switch( SHORT1FROMMP(mp1) ) 265 { 266 case CM_COPY: 267 { 268 HWND cntr = WinWindowFromID( hwnd, IDC_PROPSLIST ); 269 std::string props; 270 enumCntrEmphasis( cntr, CRA_SELECTED, addPropToString, &props ); 271 if ( !props.empty()) { 272 char *utf8 = uniSysToUtf8( props.c_str(), NULL, NULL ); 273 if ( utf8 ) 274 textToClipbrd( hab, utf8 ); 275 delete[] utf8; 276 } 277 } 278 return (MRESULT)FALSE; 279 280 case CM_SELECTALL: 281 { 282 HWND cntr = WinWindowFromID( hwnd, IDC_PROPSLIST ); 283 enumCntrRecords( cntr, selectProp, NULL ); 284 } 285 return (MRESULT)FALSE; 286 287 default: 288 break; 289 } 290 } 291 break; 236 292 } 237 293 return WinDefDlgProc( hwnd, msg, mp1, mp2 );
Note:
See TracChangeset
for help on using the changeset viewer.