Develop and Download Open Source Software

Browse CVS Repository

Diff of /gikonavigoeson/gikonavi/Gesture.pas

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.6 by h677, Wed Feb 22 17:21:22 2006 UTC revision 1.7 by h677, Sun Dec 24 15:21:09 2006 UTC
# Line 49  var Line 49  var
49    
50  implementation  implementation
51    
52    uses
53            GikoSystem;
54    
55  constructor TMouseGesture.Create;  constructor TMouseGesture.Create;
56  begin  begin
57          inherited;          inherited;
# Line 116  begin Line 119  begin
119                                  //マウスジェスチャーの対象と違うときは、開放する                                  //マウスジェスチャーの対象と違うときは、開放する
120                                  if (hwnd <> 0) and (hwnd <> FHandle) then begin                                  if (hwnd <> 0) and (hwnd <> FHandle) then begin
121                                          ReleaseCapture;                                          ReleaseCapture;
122                        SetCapture(FHandle);
123                                  end;                                  end;
                                 SetCapture(FHandle);  
124                                  dp := Point(x - FLastPoint.X, y - FLastPoint.Y);                                  dp := Point(x - FLastPoint.X, y - FLastPoint.Y);
125                                  sp := Point(Sign(dp.X), Sign(dp.Y));                                  sp := Point(Sign(dp.X), Sign(dp.Y));
126                                  if (dp.X * dp.X + dp.Y * dp.Y) > (FMargin * FMargin) then begin                                  if (dp.X * dp.X + dp.Y * dp.Y) > (FMargin * FMargin) then begin
# Line 130  begin Line 133  begin
133                                          FLastTime := GetTickCount;                                          FLastTime := GetTickCount;
134                                          FLastPoint := Point(x, y);                                          FLastPoint := Point(x, y);
135                                  end;                                  end;
136                                  Result := True;                  Result := True;
137                          end;                  end;
138                  end;                  end;
139                  WM_RBUTTONDOWN: begin                  WM_RBUTTONDOWN: begin
140                          if not FCancelMode then begin                          if (not FCancelMode)  then begin
141                    if ( GikoSys.Setting.GestureIgnoreContext ) then begin
142                                    //今マウスをキャプチャーしているのを得る
143                                    hwnd := GetCapture;
144                                    //マウスジェスチャーの対象と違うときは、開放する
145                                    if (hwnd <> 0) and (hwnd <> FHandle) then begin
146                            Exit;
147                        end;
148                    end;
149                                  FBeginGesture := True;                                  FBeginGesture := True;
150                                  FLastTime := 0;                                  FLastTime := 0;
151                                  FLastPoint := Point(x, y);                                  FLastPoint := Point(x, y);

Legend:
Removed from v.1.6  
changed lines
  Added in v.1.7

Back to OSDN">Back to OSDN
ViewVC Help
Powered by ViewVC 1.1.26