Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
73e45da4
Kaydet (Commit)
73e45da4
authored
May 14, 2015
tarafından
Tomaž Vajngerl
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
refactor chart2 classes to use RenderContext
Change-Id: I245af77126739bb219f6a085a47cee2efac2c351
üst
60758229
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
29 additions
and
29 deletions
+29
-29
ChartController.hxx
chart2/source/controller/main/ChartController.hxx
+15
-15
ChartController_Window.cxx
chart2/source/controller/main/ChartController_Window.cxx
+11
-11
ChartWindow.cxx
chart2/source/controller/main/ChartWindow.cxx
+3
-3
No files found.
chart2/source/controller/main/ChartController.hxx
Dosyayı görüntüle @
73e45da4
...
...
@@ -82,19 +82,19 @@ class WindowController
public
:
virtual
~
WindowController
()
{};
virtual
void
PrePaint
(
)
=
0
;
virtual
void
execute_Paint
(
const
Rectangle
&
rRect
)
=
0
;
virtual
void
execute_MouseButtonDown
(
const
MouseEvent
&
rMEvt
)
=
0
;
virtual
void
execute_MouseMove
(
const
MouseEvent
&
rMEvt
)
=
0
;
virtual
void
execute_Tracking
(
const
TrackingEvent
&
rTEvt
)
=
0
;
virtual
void
execute_MouseButtonUp
(
const
MouseEvent
&
rMEvt
)
=
0
;
virtual
void
execute_Resize
()
=
0
;
virtual
void
execute_Activate
()
=
0
;
virtual
void
execute_Deactivate
()
=
0
;
virtual
void
execute_GetFocus
()
=
0
;
virtual
void
execute_LoseFocus
()
=
0
;
virtual
void
execute_Command
(
const
CommandEvent
&
rCEvt
)
=
0
;
virtual
bool
execute_KeyInput
(
const
KeyEvent
&
rKEvt
)
=
0
;
virtual
void
PrePaint
(
vcl
::
RenderContext
&
rRenderContext
)
=
0
;
virtual
void
execute_Paint
(
vcl
::
RenderContext
&
rRenderContext
,
const
Rectangle
&
rRect
)
=
0
;
virtual
void
execute_MouseButtonDown
(
const
MouseEvent
&
rMEvt
)
=
0
;
virtual
void
execute_MouseMove
(
const
MouseEvent
&
rMEvt
)
=
0
;
virtual
void
execute_Tracking
(
const
TrackingEvent
&
rTEvt
)
=
0
;
virtual
void
execute_MouseButtonUp
(
const
MouseEvent
&
rMEvt
)
=
0
;
virtual
void
execute_Resize
()
=
0
;
virtual
void
execute_Activate
()
=
0
;
virtual
void
execute_Deactivate
()
=
0
;
virtual
void
execute_GetFocus
()
=
0
;
virtual
void
execute_LoseFocus
()
=
0
;
virtual
void
execute_Command
(
const
CommandEvent
&
rCEvt
)
=
0
;
virtual
bool
execute_KeyInput
(
const
KeyEvent
&
rKEvt
)
=
0
;
/** get help text to be shown in a quick help
...
...
@@ -406,8 +406,8 @@ public:
throw
(
::
com
::
sun
::
star
::
uno
::
RuntimeException
,
std
::
exception
)
SAL_OVERRIDE
;
// chart2::WindowController
virtual
void
PrePaint
()
SAL_OVERRIDE
;
virtual
void
execute_Paint
(
const
Rectangle
&
rRect
)
SAL_OVERRIDE
;
virtual
void
PrePaint
(
vcl
::
RenderContext
&
rRenderContext
)
SAL_OVERRIDE
;
virtual
void
execute_Paint
(
vcl
::
RenderContext
&
rRenderContext
,
const
Rectangle
&
rRect
)
SAL_OVERRIDE
;
virtual
void
execute_MouseButtonDown
(
const
MouseEvent
&
rMEvt
)
SAL_OVERRIDE
;
virtual
void
execute_MouseMove
(
const
MouseEvent
&
rMEvt
)
SAL_OVERRIDE
;
virtual
void
execute_Tracking
(
const
TrackingEvent
&
rTEvt
)
SAL_OVERRIDE
;
...
...
chart2/source/controller/main/ChartController_Window.cxx
Dosyayı görüntüle @
73e45da4
...
...
@@ -449,34 +449,34 @@ void SAL_CALL ChartController::removePaintListener(
}
// impl vcl window controller methods
void
ChartController
::
PrePaint
()
void
ChartController
::
PrePaint
(
vcl
::
RenderContext
&
/*rRenderContext*/
)
{
// forward VCLs PrePaint window event to DrawingLayer
DrawViewWrapper
*
pDrawViewWrapper
=
m_pDrawViewWrapper
;
if
(
pDrawViewWrapper
)
if
(
pDrawViewWrapper
)
{
pDrawViewWrapper
->
PrePaint
();
}
}
void
ChartController
::
execute_Paint
(
const
Rectangle
&
rRect
)
void
ChartController
::
execute_Paint
(
vcl
::
RenderContext
&
rRenderContext
,
const
Rectangle
&
rRect
)
{
try
{
uno
::
Reference
<
frame
::
XModel
>
xModel
(
getModel
()
);
uno
::
Reference
<
frame
::
XModel
>
xModel
(
getModel
()
);
//OSL_ENSURE( xModel.is(), "ChartController::execute_Paint: have no model to paint");
if
(
!
xModel
.
is
()
)
if
(
!
xModel
.
is
()
)
return
;
//better performance for big data
uno
::
Reference
<
beans
::
XPropertySet
>
xProp
(
m_xChartView
,
uno
::
UNO_QUERY
);
if
(
xProp
.
is
()
)
uno
::
Reference
<
beans
::
XPropertySet
>
xProp
(
m_xChartView
,
uno
::
UNO_QUERY
);
if
(
xProp
.
is
()
)
{
awt
::
Size
aResolution
(
1000
,
1000
);
{
SolarMutexGuard
aGuard
;
if
(
m_pChartWindow
)
if
(
m_pChartWindow
)
{
aResolution
.
Width
=
m_pChartWindow
->
GetSizePixel
().
Width
();
aResolution
.
Height
=
m_pChartWindow
->
GetSizePixel
().
Height
();
...
...
@@ -486,14 +486,14 @@ void ChartController::execute_Paint( const Rectangle& rRect )
}
uno
::
Reference
<
util
::
XUpdatable
>
xUpdatable
(
m_xChartView
,
uno
::
UNO_QUERY
);
if
(
xUpdatable
.
is
()
)
if
(
xUpdatable
.
is
()
)
xUpdatable
->
update
();
{
SolarMutexGuard
aGuard
;
DrawViewWrapper
*
pDrawViewWrapper
=
m_pDrawViewWrapper
;
if
(
pDrawViewWrapper
)
pDrawViewWrapper
->
CompleteRedraw
(
m_pChartWindow
,
vcl
::
Region
(
rRect
)
);
if
(
pDrawViewWrapper
)
pDrawViewWrapper
->
CompleteRedraw
(
&
rRenderContext
,
vcl
::
Region
(
rRect
)
);
}
}
catch
(
const
uno
::
Exception
&
ex
)
...
...
chart2/source/controller/main/ChartWindow.cxx
Dosyayı görüntüle @
73e45da4
...
...
@@ -93,12 +93,12 @@ void ChartWindow::clear()
this
->
ReleaseMouse
();
}
void
ChartWindow
::
PrePaint
(
vcl
::
RenderContext
&
/*rRenderContext*/
)
void
ChartWindow
::
PrePaint
(
vcl
::
RenderContext
&
rRenderContext
)
{
// forward VCLs PrePaint window event to DrawingLayer
if
(
m_pWindowController
)
{
m_pWindowController
->
PrePaint
();
m_pWindowController
->
PrePaint
(
rRenderContext
);
}
}
...
...
@@ -111,7 +111,7 @@ void ChartWindow::Paint(vcl::RenderContext& rRenderContext, const Rectangle& rRe
}
else
if
(
m_pWindowController
)
{
m_pWindowController
->
execute_Paint
(
rRect
);
m_pWindowController
->
execute_Paint
(
rRe
nderContext
,
rRe
ct
);
}
else
{
...
...
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