Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
M
magicseteditor
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
MyCard
magicseteditor
Commits
c6a84f9b
Commit
c6a84f9b
authored
Apr 29, 2007
by
twanvl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed: card box not resized when rotating cards
parent
ed0c9281
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
4 deletions
+5
-4
src/render/card/viewer.cpp
src/render/card/viewer.cpp
+3
-3
src/render/card/viewer.hpp
src/render/card/viewer.hpp
+2
-1
No files found.
src/render/card/viewer.cpp
View file @
c6a84f9b
...
...
@@ -67,9 +67,9 @@ Rotation DataViewer::getRotation() const {
// ----------------------------------------------------------------------------- : Setting data
void
DataViewer
::
setCard
(
const
CardP
&
card
)
{
void
DataViewer
::
setCard
(
const
CardP
&
card
,
bool
refresh
)
{
if
(
!
card
)
return
;
// TODO: clear viewer?
if
(
this
->
card
==
card
&&
this
->
stylesheet
==
set
->
stylesheetFor
(
card
))
return
;
// already set
if
(
!
refresh
&&
this
->
card
==
card
&&
this
->
stylesheet
==
set
->
stylesheetFor
(
card
))
return
;
// already set
assert
(
set
);
this
->
card
=
card
;
stylesheet
=
set
->
stylesheetFor
(
card
);
...
...
@@ -124,7 +124,7 @@ ValueViewerP DataViewer::makeViewer(const StyleP& style) {
void
DataViewer
::
onAction
(
const
Action
&
action
,
bool
undone
)
{
TYPE_CASE_
(
action
,
DisplayChangeAction
)
{
// refresh
setCard
(
card
);
setCard
(
card
,
true
);
return
;
}
TYPE_CASE
(
action
,
ValueAction
)
{
...
...
src/render/card/viewer.hpp
View file @
c6a84f9b
...
...
@@ -60,7 +60,8 @@ class DataViewer : public SetView {
// --------------------------------------------------- : Setting data
/// Display a card in this viewer
void
setCard
(
const
CardP
&
card
);
/** \param refresh: Always refresh, even if this card is already shown */
void
setCard
(
const
CardP
&
card
,
bool
refresh
=
false
);
// --------------------------------------------------- : The viewers
protected:
...
...
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