Changeset 152 for trunk/Lucide


Ignore:
Timestamp:
Nov 6, 2006, 6:03:44 PM (15 years ago)
Author:
Eugene Romanenko
Message:

pipe commands

Location:
trunk/Lucide
Files:
1 added
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/Lucide/SOURCE/gui/Lucide_res.H

    r129 r152  
    9595#define CM_PRODINFO     601
    9696
     97// No menuitems for this commands
     98#define CM_MINIMIZE     701
     99#define CM_TOFULLSCREEN 702
     100
    97101#define TBID_PAGENUM    1
    98102#define TBID_OFPAGES    2
  • trunk/Lucide/SOURCE/gui/lucide.cpp

    r138 r152  
    7575HWND createToolbar( HWND hwnd );
    7676void AboutBox( HWND hWndFrame );
     77void initPipeMon( HWND hWndFrame );
     78void unInitPipeMon();
    7779
    7880HAB   hab            = NULLHANDLE;
     
    614616}
    615617
     618void Lucide::cmdMinimize()
     619{
     620    if ( isFullscreen ) {
     621        toggleFullscreen();
     622    }
     623    WinSetWindowPos( hWndFrame, HWND_TOP, 0, 0, 0, 0, SWP_MINIMIZE );
     624}
     625
     626void Lucide::cmdSwitchToFullscreen()
     627{
     628    if ( !isFullscreen )
     629    {
     630        SWP pos = {0};
     631        WinQueryWindowPos( hWndFrame, &pos );
     632
     633        if ( pos.fl & SWP_MINIMIZE ) {
     634            WinSetWindowPos( hWndFrame, HWND_TOP, 0, 0, 0, 0,
     635                    SWP_SHOW | SWP_ACTIVATE | SWP_RESTORE | SWP_ZORDER );
     636        }
     637        toggleFullscreen();
     638    }
     639}
     640
    616641static MRESULT EXPENTRY splProc( HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2 )
    617642{
     
    807832                    return (MRESULT)FALSE;
    808833
     834                case CM_MINIMIZE:
     835                    Lucide::cmdMinimize();
     836                    return (MRESULT)FALSE;
     837
     838                case CM_TOFULLSCREEN:
     839                    Lucide::cmdSwitchToFullscreen();
     840                    return (MRESULT)FALSE;
    809841            }
    810842        }
     
    902934
    903935    Lucide::checkNavpane();
     936    initPipeMon( hWndFrame );
    904937
    905938    // Messsage loop
     
    930963    delete title;
    931964    delete settings;
     965    unInitPipeMon();
    932966
    933967    WinDestroyMsgQueue( hmq );
  • trunk/Lucide/SOURCE/gui/lucide.h

    r122 r152  
    9494        static void toggleFullscreen();
    9595        static void focusDocview();
     96        static void cmdMinimize();
     97        static void cmdSwitchToFullscreen();
    9698};
    9799
  • trunk/Lucide/SOURCE/gui/makefile

    r150 r152  
    3737       fontsInfoDlg.obj docInfoDlg.obj findDlg.obj progressDlg.obj \
    3838       aboutDlg.obj settingsDlg.obj lusettings.obj printDlg.obj \
    39        print.obj stbrowser.obj
     39       print.obj stbrowser.obj pipemon.obj
    4040
    4141lucide.dll: $(OBJS) lucide.res
     
    6969file $(OBJDIR)\messages.obj
    7070file $(OBJDIR)\stbrowser.obj
     71file $(OBJDIR)\pipemon.obj
    7172name $(EXEDIR)\lucide
    7273lib ..\plugins\ludoc\ludoc
     
    123124intern.obj:         intern.cpp
    124125messages.obj:       messages.cpp
     126pipemon.obj:        pipemon.cpp
    125127linklab.obj:        linklab.c
    126128wwbtn.obj:          wwbtn.c
  • trunk/Lucide/changelog

    r151 r152  
    11Beta-5:
     2  - Pipe commands, see readme for details.
    23  - PDF plugin: freetype library updated to version 2.2.1.
    34  - Updated NLS-files: Spanish, German...
  • trunk/Lucide/readme

    r108 r152  
    3838
    3939
     40:: Pipe commands ::
     41
     42First instance of Lucide will create named pipe \PIPE\LUCIDE. You may
     43send following commands to pipe:
     44
     45$prev              - will switch to previous page
     46$next              - will switch to next page
     47$switchfullscreen  - will switch to fullscreen (even if minimized)
     48$minimize          - will mimimize Lucide (even if fullscreen)
     49
     50This may be useful for presentations with remote control.
     51
     52
    4053:: License ::
    4154
Note: See TracChangeset for help on using the changeset viewer.