From cf47df5e914242a09cc95a67a99cfad48fa8cdf8 Mon Sep 17 00:00:00 2001 From: mattias Date: Sun, 29 Jul 2007 13:50:17 +0000 Subject: [PATCH] LCL: removed dummy function SetMapMode git-svn-id: trunk@11668 - --- lcl/include/intfbasewinapi.inc | 5 -- lcl/include/winapi.inc | 5 -- lcl/include/winapih.inc | 1 - lcl/interfaces/qt/qtwinapi.inc | 88 --------------------------------- lcl/interfaces/qt/qtwinapih.inc | 1 - 5 files changed, 100 deletions(-) diff --git a/lcl/include/intfbasewinapi.inc b/lcl/include/intfbasewinapi.inc index df016e29e4..0d50233e5a 100644 --- a/lcl/include/intfbasewinapi.inc +++ b/lcl/include/intfbasewinapi.inc @@ -1337,11 +1337,6 @@ begin Result := false; end; -function TWidgetSet.SetMapMode(DC: HDC; MapMode: Integer): Integer; -begin - Result := 0; -end; - Function TWidgetSet.SetProp(Handle: hwnd; Str : PChar; Data : Pointer) : Boolean; Begin diff --git a/lcl/include/winapi.inc b/lcl/include/winapi.inc index d49274ab19..0c4857c7bc 100644 --- a/lcl/include/winapi.inc +++ b/lcl/include/winapi.inc @@ -758,11 +758,6 @@ begin Result := WidgetSet.SetForegroundWindow(hWnd); end; -function SetMapMode(DC: HDC; MapMode: Integer): Integer; -begin - Result := WidgetSet.SetMapMode(DC,MapMode); -end; - function SetScrollInfo(Handle : HWND; SBStyle : Integer; ScrollInfo: TScrollInfo; Redraw : Boolean): Integer; begin diff --git a/lcl/include/winapih.inc b/lcl/include/winapih.inc index 87ecff368c..5a33c41d08 100644 --- a/lcl/include/winapih.inc +++ b/lcl/include/winapih.inc @@ -208,7 +208,6 @@ function SetCursor(hCursor: HICON): HCURSOR; {$IFDEF IF_BASE_MEMBER}virtual;{$EN function SetCursorPos(X, Y: Integer): Boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF} function SetFocus(hWnd: HWND): HWND; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF} function SetForegroundWindow(hWnd : HWND): Boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF} -function SetMapMode(DC: HDC; MapMode: Integer): Integer; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF} function SetProp(Handle: hwnd; Str : PChar; Data : Pointer) : Boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF} //function SetRect --> independent //function SetRectEmpty --> independent diff --git a/lcl/interfaces/qt/qtwinapi.inc b/lcl/interfaces/qt/qtwinapi.inc index 7fcbf2f932..b44fae7d42 100644 --- a/lcl/interfaces/qt/qtwinapi.inc +++ b/lcl/interfaces/qt/qtwinapi.inc @@ -3999,94 +3999,6 @@ begin Result := True; end; -{------------------------------------------------------------------------------ - Function: TQtWidgetSet.SetMapMode - Params: DC: HDC; MapMode: Integer - Returns: Integer - - ------------------------------------------------------------------------------} -function TQtWidgetSet.SetMapMode(DC: HDC; MapMode: Integer): Integer; -var - Matrix: QMatrixH; - MatrixNew: QMatrixH; - dpi: TSize; - m11, m22: Double; - dx, dy: Double; - QtDC: TQtDeviceContext; - -procedure SetM(const Am11, Am22: Double); -begin - m11 := Am11; - m22 := Am22; -end; - -begin - {$ifdef VerboseQtWinAPI} - WriteLn('[WinAPI SetMapMode] DC: ',dbghex(DC),' MapMode: ',MapMode); - {$endif} - - Result := 0; - if not IsValidDC(DC) then exit; - - {$note implement - wait for LCL} - - {$ifdef VerboseQtWinAPI_MISSING_IMPLEMENTATION} - WriteLn('***** [WinAPI TQtWidgetSet.SetMapMode] missing implementation '); - {$endif} - - (* - QtDC := TQtDeviceContext(DC); - - dpi.cx := GetDeviceCaps(DC, LOGPIXELSX); - dpi.cy := GetDeviceCaps(DC, LOGPIXELSY); - - Result := GetMapMode(DC); - - case MapMode of - MM_TEXT: - SetM(1, 1); - - MM_LOMETRIC: - SetM((dpi.cx / 2.54) / 100, -(dpi.cy / 2.54) / 100); - MM_HIMETRIC: - SetM((dpi.cx / 2.54) / 1000, -(dpi.cy / 2.54) / 1000); - - MM_LOENGLISH: - SetM(dpi.cx / 10, -dpi.cy / 10); - MM_HIENGLISH: - SetM(dpi.cx / 100, -dpi.cy / 100); - - MM_TWIPS: - SetM(dpi.cx / 1440, -dpi.cy / 1440); - - MM_ISOTROPIC: - - end; - - Matrix := QPainter_matrix(QtDC.Widget); - - if QPainter_worldMatrixEnabled(QtDC.Widget) then - begin - Matrix := QPainter_worldMatrix(QtDC.Widget); - dx := QMatrix_dx(Matrix); - dy := QMatrix_dy(Matrix); - end else - begin - dx := 0; - dy := 0; - end; - - MatrixNew := QMatrix_create(m11, 0, 0, m22, dx, dy); - try - QPainter_setWorldMatrix(QtDC.Widget, MatrixNew, False); - finally - QMatrix_destroy(MatrixNew); - end; - - Result := MapMode; - *) - -end; {------------------------------------------------------------------------------ Function: SetFocus Params: hWnd - Window handle to be focused diff --git a/lcl/interfaces/qt/qtwinapih.inc b/lcl/interfaces/qt/qtwinapih.inc index 41254d58bb..10528c24ae 100644 --- a/lcl/interfaces/qt/qtwinapih.inc +++ b/lcl/interfaces/qt/qtwinapih.inc @@ -176,7 +176,6 @@ function SetCursor(ACursor: HCURSOR): HCURSOR; override; function SetCursorPos(X, Y: Integer): Boolean; override; function SetFocus(hWnd: HWND): HWND; override; function SetForegroundWindow(HWnd: HWND): boolean; override; -function SetMapMode(DC: HDC; MapMode: Integer): Integer; override; function SetProp(Handle: hwnd; Str : PChar; Data : Pointer) : Boolean; override; function SetScrollInfo(Handle : HWND; SBStyle : Integer; ScrollInfo: TScrollInfo; bRedraw : Boolean): Integer; override; function SetTextColor(DC: HDC; Color: TColorRef): TColorRef; override;