/Users/ericb/Desktop/NATIVEPRINTDLG01/extensions/source/scanner/scanwin.cxx File Reference

#include "precompiled_extensions.hxx"
#include <com/sun/star/uno/Any.hxx>
#include <com/sun/star/uno/Reference.hxx>
#include <com/sun/star/util/XCloseable.hpp>
#include <com/sun/star/util/XCloseBroadcaster.hpp>
#include <com/sun/star/util/XCloseListener.hpp>
#include <com/sun/star/frame/XFrame.hpp>
#include <com/sun/star/frame/XDesktop.hpp>
#include <com/sun/star/beans/XPropertySet.hpp>
#include <cppuhelper/implbase1.hxx>
#include <comphelper/processfactory.hxx>
#include <math.h>
#include <tools/svwin.h>
#include <tools/stream.hxx>
#include <vos/mutex.hxx>
#include <vos/module.hxx>
#include <vcl/svapp.hxx>
#include <vcl/wrkwin.hxx>
#include <vcl/sysdata.hxx>
#include <vcl/salbtype.hxx>
#include "scanner.hxx"
#include "twain/twain.h"

Include dependency graph for scanwin.cxx:

Go to the source code of this file.

Classes

class  ImpTwain
class  Twain

Defines

#define TWAIN_SELECT   0x00000001UL
#define TWAIN_ACQUIRE   0x00000002UL
#define TWAIN_TERMINATE   0xFFFFFFFFUL
#define TWAIN_EVENT_NONE   0x00000000UL
#define TWAIN_EVENT_QUIT   0x00000001UL
#define TWAIN_EVENT_SCANNING   0x00000002UL
#define TWAIN_EVENT_XFER   0x00000004UL
#define PFUNC   (*pDSM)
#define PTWAINMSG   MSG*
#define FIXTODOUBLE(nFix)   ((double)nFix.Whole+(double)nFix.Frac/65536.)
#define FIXTOLONG(nFix)   ((long)floor(FIXTODOUBLE(nFix)+0.5))

Enumerations

enum  TwainState { TWAIN_STATE_NONE = 0, TWAIN_STATE_SCANNING = 1, TWAIN_STATE_DONE = 2, TWAIN_STATE_CANCELED = 3 }

Functions

LRESULT CALLBACK TwainWndProc (HWND hWnd, UINT nMsg, WPARAM nPar1, LPARAM nPar2)
LRESULT CALLBACK TwainMsgProc (int nCode, WPARAM wParam, LPARAM lParam)
 IMPL_LINK (ImpTwain, ImplFallbackHdl, void *, pData)
 IMPL_LINK (ImpTwain, ImplDestroyHdl, void *,)
 IMPL_LINK (Twain, ImpNotifyHdl, ImpTwain *, nEvent)
 SEQ (sal_Int8) ScannerManager
 SEQ (ScannerContext) SAL_CALL ScannerManager

Variables

static ImpTwainpImpTwainInstance = NULL
static Twain aTwain


Define Documentation

#define FIXTODOUBLE ( nFix   )     ((double)nFix.Whole+(double)nFix.Frac/65536.)

Definition at line 112 of file scanwin.cxx.

#define FIXTOLONG ( nFix   )     ((long)floor(FIXTODOUBLE(nFix)+0.5))

Definition at line 113 of file scanwin.cxx.

Referenced by ImpTwain::ImplXfer().

#define PFUNC   (*pDSM)

Definition at line 110 of file scanwin.cxx.

Referenced by IMPL_LINK(), ImpTwain::ImplEnableSource(), ImpTwain::ImplHandleMsg(), ImpTwain::ImplOpenSource(), ImpTwain::ImplOpenSourceManager(), ImpTwain::ImplXfer(), and ImpTwain::SelectSource().

#define PTWAINMSG   MSG*

Definition at line 111 of file scanwin.cxx.

Referenced by ImpTwain::ImplHandleMsg().

#define TWAIN_ACQUIRE   0x00000002UL

Definition at line 102 of file scanwin.cxx.

#define TWAIN_EVENT_NONE   0x00000000UL

Definition at line 105 of file scanwin.cxx.

Referenced by ImpTwain::Destroy(), and IMPL_LINK().

#define TWAIN_EVENT_QUIT   0x00000001UL

Definition at line 106 of file scanwin.cxx.

Referenced by IMPL_LINK(), ImpTwain::ImplHandleMsg(), ImpTwain::ImpTwain(), ImpTwain::InitXfer(), and ImpTwain::SelectSource().

#define TWAIN_EVENT_SCANNING   0x00000002UL

Definition at line 107 of file scanwin.cxx.

Referenced by IMPL_LINK(), ImpTwain::ImplEnableSource(), and ImpTwain::SelectSource().

#define TWAIN_EVENT_XFER   0x00000004UL

Definition at line 108 of file scanwin.cxx.

Referenced by IMPL_LINK(), and ImpTwain::ImplHandleMsg().

#define TWAIN_SELECT   0x00000001UL

Definition at line 101 of file scanwin.cxx.

#define TWAIN_TERMINATE   0xFFFFFFFFUL

Definition at line 103 of file scanwin.cxx.


Enumeration Type Documentation

enum TwainState

Enumerator:
TWAIN_STATE_NONE 
TWAIN_STATE_SCANNING 
TWAIN_STATE_DONE 
TWAIN_STATE_CANCELED 

Definition at line 127 of file scanwin.cxx.


Function Documentation

IMPL_LINK ( Twain  ,
ImpNotifyHdl  ,
ImpTwain ,
nEvent   
)

Definition at line 866 of file scanwin.cxx.

References TWAIN_EVENT_QUIT, TWAIN_EVENT_SCANNING, TWAIN_EVENT_XFER, TWAIN_STATE_CANCELED, TWAIN_STATE_DONE, and TWAIN_STATE_SCANNING.

IMPL_LINK ( ImpTwain  ,
ImplDestroyHdl  ,
void *   
)

Definition at line 591 of file scanwin.cxx.

References pImpTwainInstance.

IMPL_LINK ( ImpTwain  ,
ImplFallbackHdl  ,
void *  ,
pData   
)

Definition at line 517 of file scanwin.cxx.

References PFUNC, and TWAIN_EVENT_NONE.

SEQ ( ScannerContext   ) 

Definition at line 1028 of file scanwin.cxx.

References SEQ.

SEQ ( sal_Int8   ) 

Definition at line 966 of file scanwin.cxx.

References SEQ.

LRESULT CALLBACK TwainMsgProc ( int  nCode,
WPARAM  wParam,
LPARAM  lParam 
)

Definition at line 205 of file scanwin.cxx.

References ImpTwain::hTwainHook, ImpTwain::hTwainWnd, ImpTwain::ImplHandleMsg(), and pImpTwainInstance.

LRESULT CALLBACK TwainWndProc ( HWND  hWnd,
UINT  nMsg,
WPARAM  nPar1,
LPARAM  nPar2 
)

Definition at line 198 of file scanwin.cxx.

Referenced by ImpTwain::ImpTwain().


Variable Documentation

Twain aTwain [static]

Definition at line 922 of file scanwin.cxx.

ImpTwain* pImpTwainInstance = NULL [static]

Definition at line 194 of file scanwin.cxx.

Referenced by IMPL_LINK(), ImpTwain::ImpTwain(), and TwainMsgProc().


Generated on Thu Feb 28 17:53:31 2008 for AquaScanner by  doxygen 1.5.1