Changeset 267


Ignore:
Timestamp:
Feb 24, 2009, 3:52:22 PM (12 years ago)
Author:
Eugene Romanenko
Message:

close menuitem

Location:
trunk/Lucide
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/Lucide/BIN/Lucide.lng

    r243 r267  
    1717MENU_CLEAR_LIST=~Clear list
    1818MENU_SAVE_AS=~Save As...
     19MENU_CLOSE=~Close
    1920# MENU_PAGE_SETUP: to delete
    2021MENU_PAGE_SETUP=Pa~ge setup...
  • trunk/Lucide/BIN/Lucide_ru.lng

    r243 r267  
    1414MENU_NEXT=‘«¥€ãîéš©\tShift+PgDn
    1515MENU_LAST=®á«¥€­š©\tShift+End
     16MENU_RECENT_FILES=¥~€ ¢­š¥ ä ©«ë
     17MENU_CLEAR_LIST=~Žçšáâšâì
    1618MENU_SAVE_AS=~‘®åà ­šâì ª ª...
     19MENU_CLOSE=~‡ ªàëâì
    1720# MENU_PAGE_SETUP: to delete
    1821MENU_PAGE_SETUP= ~à ¬¥âàë áâà ­šæë...
  • trunk/Lucide/SOURCE/gui/Lucide.rc

    r246 r267  
    4040        END
    4141        MENUITEM "MENU_SAVE_AS", CM_SAVEAS
     42        MENUITEM "MENU_CLOSE", CM_CLOSE
    4243        MENUITEM SEPARATOR
    4344        MENUITEM "MENU_PRINT", CM_PRINT
  • trunk/Lucide/SOURCE/gui/Lucide_res.H

    r243 r267  
    6363#define CM_OPEN         102
    6464#define CM_SAVEAS       103
    65 #define CM_PRINT        104
    66 #define CM_PLUGINSLIST  105
    67 #define CM_EXIT         106
     65#define CM_CLOSE        104
     66#define CM_PRINT        105
     67#define CM_PLUGINSLIST  106
     68#define CM_EXIT         107
    6869
    6970#define CM_FILEFIRST    151
  • trunk/Lucide/SOURCE/gui/lucide.cpp

    r238 r267  
    263263
    264264        WinEnableMenuItem( hWndMenu, CM_SAVEAS, FALSE );
     265        WinEnableMenuItem( hWndMenu, CM_CLOSE, FALSE );
    265266        WinEnableMenuItem( hWndMenu, CM_PRINT, FALSE );
    266267        WinSendMsg( hToolBar, TBM_ENABLEITEM, MPFROMSHORT(CM_PRINT), (MPARAM)FALSE );
     
    313314    WinSendMsg( hToolBar, TBM_ENABLEITEM, MPFROMSHORT(CM_PRINT), (MPARAM)TRUE );
    314315    WinEnableMenuItem( hWndMenu, CM_SAVEAS, doc->isSaveable( ev ) );
     316    WinEnableMenuItem( hWndMenu, CM_CLOSE, TRUE );
    315317    setOfPages( doc->getPageCount( ev ) );
    316318    WinEnableMenuItem( hWndMenu, CM_FONTSINFO, doc->isHaveFontInfo( ev ) );
     
    365367void Lucide::closeDocument()
    366368{
    367     docViewer->close();
    368     delete doc;
    369     doc = NULL;
    370     WinSetWindowText( hWndFrame, title );
    371     checkMenus( false );
     369    if ( doc != NULL ) {   
     370        docViewer->close();
     371        delete doc;
     372        doc = NULL;
     373        WinSetWindowText( hWndFrame, title );
     374        checkMenus( false );
     375    }
    372376
    373377    if ( thumbnailData != NULL ) {
     
    961965                    Lucide::saveDocumentAs();
    962966                    return (MRESULT)FALSE;
     967                   
     968                case CM_CLOSE:
     969                    Lucide::closeDocument();
     970                    return (MRESULT)FALSE;
    963971
    964972                case CM_PRINT:
Note: See TracChangeset for help on using the changeset viewer.