TvPlanIt: Avoid windows-like messages in printing routines (fixes crashes in cocoa related to PrintPreview).

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@8888 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
wp_xxyyzz
2023-07-21 20:18:22 +00:00
parent d5965cb872
commit d9d497757b
6 changed files with 111 additions and 62 deletions

View File

@@ -1014,7 +1014,7 @@ var
begin
if FNotifiers <> nil then
begin
{$IFDEF LCl}
{$IFDEF LCL}
i := FNotifiers.IndexOf(Watcher);
if i = -1 then
FNotifiers.Add(Watcher);
@@ -1375,10 +1375,10 @@ procedure TVpResourceCombo.InternalSetDatastore(const Value: TVpCustomDatastore)
begin
if FDataStore <> Value then begin
if Assigned (FDataStore) and not (csDesigning in ComponentState) then
FDataStore.DeregisterWatcher(Self); //Handle);
FDataStore.DeregisterWatcher({$IFDEF LCL}Self{$ELSE}Handle{$ENDIF});
FDataStore := Value;
if Assigned (FDataStore) and not (csDesigning in ComponentState) then
FDataStore.RegisterWatcher(Self); //Handle);
FDataStore.RegisterWatcher({$IFDEF LCL}Self{$ELSE}Handle{$ENDIF});
if not (csDesigning in ComponentState) then
LoadItems;
Invalidate;