Beispiel #1
0
Err DIA_FrmEnableDIA(const DIA_Settings* diaSettings, FormType* form, Coord minH, Coord prefH, Coord maxH, Coord minW, Coord prefW, Coord maxW) 
{
    Err         error;
    WinHandle   wh;

    Assert(diaSettings);
    Assert(form);

    if (DIA_HasSonySilkLib(diaSettings))
        DIA_HandleResizeEvent();

    if (!DIA_HasPenInputMgr(diaSettings))
        return errNone;

    error=FrmSetDIAPolicyAttr(form, frmDIAPolicyCustom);
    if (error) 
        goto OnError;

    wh=FrmGetWindowHandle(form);
    Assert(wh);

    error=PINSetInputTriggerState(pinInputTriggerEnabled);
    error=WinSetConstraintsSize(wh, minH, prefH, maxH, minW, prefW, maxW);
    error=PINSetInputAreaState(pinInputAreaUser);
    error = errNone;
    
OnError:
    if (error==pinErrNoSoftInputArea) 
        error=errNone;
    return error;
}
static void setPalmDynInputParams(FormType *frmP) {
	Err err;
	Boolean dia=dynamicInputAvail();
	if(dia) {
		WinHandle frmH;
		err=FrmSetDIAPolicyAttr(frmP,frmDIAPolicyCustom);
		if(!err) {
			err=PINSetInputTriggerState(pinInputTriggerEnabled);
		}
		frmH=FrmGetWindowHandle(frmP);
		WinSetConstraintsSize(frmH,160,160,640,160,160,640);
	}
}
Beispiel #3
0
void SetDIAConstraints( WinHandle winH, Boolean big, Boolean allowBig )
{
#ifdef HAVE_PALM_DIA_SDK
    if ( hardware == DIA_HARDWARE_PALM10 || hardware == DIA_HARDWARE_PALM11 ) {
        PushCoordinateSystemToStandard();

        WinSetConstraintsSize( winH,
            STD_EXTENT_Y,
            big ? MAX_EXTENT_Y : STD_EXTENT_Y,
            allowBig ? MAX_EXTENT_Y : STD_EXTENT_Y,
            STD_EXTENT_X,
            big ? MAX_EXTENT_X : STD_EXTENT_X,
            allowBig ? MAX_EXTENT_X : STD_EXTENT_X );

        PopCoordinateSystem();
    }
#endif
}