Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
K
kicad-source-mirror
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
Elphel
kicad-source-mirror
Commits
148baffd
Commit
148baffd
authored
Sep 21, 2010
by
Marco Serantoni
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
OSX implementation of wxOverlay (speedups board operations) and cleanup
parent
27e9eedd
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
28 additions
and
7 deletions
+28
-7
class_drawpanel.h
include/class_drawpanel.h
+5
-0
controle.cpp
pcbnew/controle.cpp
+9
-3
modules.cpp
pcbnew/modules.cpp
+1
-4
tracepcb.cpp
pcbnew/tracepcb.cpp
+13
-0
No files found.
include/class_drawpanel.h
View file @
148baffd
...
...
@@ -8,6 +8,7 @@
#include "colors.h"
#include "base_struct.h"
#include <wx/overlay.h>
class
WinEDA_DrawFrame
;
class
BASE_SCREEN
;
...
...
@@ -60,6 +61,10 @@ public:
int
m_CursorLevel
;
// Index for cursor redraw in XOR
// mode
#ifdef __WXMAC__
// MAC Uses overlay to workaround the wxINVERT and wxXOR miss
wxOverlay
m_overlay
;
#endif
/* Cursor management (used in editing functions) */
/* Mouse capture move callback function prototype. */
...
...
pcbnew/controle.cpp
View file @
148baffd
...
...
@@ -362,11 +362,17 @@ void WinEDA_PcbFrame::GeneralControle( wxDC* DC, wxPoint Mouse )
if
(
DrawPanel
->
ManageCurseur
)
{
#ifdef __WXMAC__
DrawPanel
->
Refresh
();
DrawPanel
->
Update
();
#endif
wxDCOverlay
oDC
(
DrawPanel
->
m_overlay
,
DC
);
oDC
.
Clear
();
DrawPanel
->
ManageCurseur
(
DrawPanel
,
DC
,
FALSE
);
#else
DrawPanel
->
ManageCurseur
(
DrawPanel
,
DC
,
TRUE
);
#endif
}
#ifdef __WXMAC__
else
DrawPanel
->
m_overlay
.
Reset
();
#endif
}
if
(
hotkey
)
...
...
pcbnew/modules.cpp
View file @
148baffd
...
...
@@ -571,11 +571,8 @@ void DrawModuleOutlines( WinEDA_DrawPanel* panel, wxDC* DC, MODULE* module )
if
(
g_Show_Pads_Module_in_Move
)
{
pad_fill_tmp
=
DisplayOpt
.
DisplayPadFill
;
#ifndef __WXMAC__
DisplayOpt
.
DisplayPadFill
=
true
;
#else
DisplayOpt
.
DisplayPadFill
=
false
;
#endif
pt_pad
=
module
->
m_Pads
;
for
(
;
pt_pad
!=
NULL
;
pt_pad
=
pt_pad
->
Next
()
)
{
...
...
pcbnew/tracepcb.cpp
View file @
148baffd
...
...
@@ -18,6 +18,7 @@
#include "module_editor_frame.h"
#include "pcbplot.h"
#include "protos.h"
#include <wx/overlay.h>
extern
int
g_DrawDefaultLineThickness
;
// Default line thickness, used to draw Frame references
...
...
@@ -53,6 +54,12 @@ void WinEDA_ModuleEditFrame::RedrawActiveWindow( wxDC* DC, bool EraseBg )
module
->
Draw
(
DrawPanel
,
DC
,
GR_OR
);
}
#ifdef __WXMAC__
DrawPanel
->
m_overlay
.
Reset
();
wxDCOverlay
overlaydc
(
DrawPanel
->
m_overlay
,
DC
);
overlaydc
.
Clear
();
#endif
screen
->
ClrRefreshReq
();
if
(
DrawPanel
->
ManageCurseur
)
...
...
@@ -83,6 +90,12 @@ void WinEDA_PcbFrame::RedrawActiveWindow( wxDC* DC, bool EraseBg )
DrawGeneralRatsnest
(
DC
);
#ifdef __WXMAC__
DrawPanel
->
m_overlay
.
Reset
();
wxDCOverlay
overlaydc
(
DrawPanel
->
m_overlay
,
DC
);
overlaydc
.
Clear
();
#endif
GetScreen
()
->
ClrRefreshReq
();
if
(
DrawPanel
->
ManageCurseur
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment