Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
Tusooa Zhu
Krita
Commits
ed4aaf35
Commit
ed4aaf35
authored
Oct 02, 2014
by
Timothée Giet
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Revert "Fix frame selection broken due to frame dragging."
This reverts commit ba505b0b2f419fcac2d63cb0ad99bf1faa5d1141.
parent
3cf7bfca
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
8 additions
and
24 deletions
+8
-24
krita/plugins/extensions/dockers/animator/kis_animation_frame.cpp
...ugins/extensions/dockers/animator/kis_animation_frame.cpp
+8
-15
krita/plugins/extensions/dockers/animator/kis_animation_frame.h
...plugins/extensions/dockers/animator/kis_animation_frame.h
+0
-1
krita/plugins/extensions/dockers/animator/kis_layer_contents.cpp
...lugins/extensions/dockers/animator/kis_layer_contents.cpp
+0
-6
krita/plugins/extensions/dockers/animator/kis_layer_contents.h
.../plugins/extensions/dockers/animator/kis_layer_contents.h
+0
-2
No files found.
krita/plugins/extensions/dockers/animator/kis_animation_frame.cpp
View file @
ed4aaf35
...
...
@@ -27,7 +27,6 @@ KisAnimationFrame::KisAnimationFrame(KisLayerContents *parent, int type, int wid
this
->
m_width
=
width
;
this
->
setParent
(
parent
);
this
->
m_parent
=
parent
;
m_dragging
=
false
;
}
void
KisAnimationFrame
::
paintEvent
(
QPaintEvent
*
event
)
...
...
@@ -58,7 +57,9 @@ void KisAnimationFrame::mouseMoveEvent(QMouseEvent *event)
{
if
(
m_mousePressed
)
{
m_dragging
=
true
;
if
(
this
->
m_type
==
KisAnimationFrame
::
SELECTION
)
{
return
;
}
int
x
=
event
->
globalX
();
...
...
@@ -77,21 +78,13 @@ void KisAnimationFrame::mousePressEvent(QMouseEvent *event)
void
KisAnimationFrame
::
mouseReleaseEvent
(
QMouseEvent
*
event
)
{
m_mousePressed
=
false
;
m_mousePressEndPoint
=
event
->
globalX
();
if
(
m_dragging
)
{
m_dragging
=
false
;
m_mousePressEndPoint
=
event
->
globalX
();
int
x
=
(
this
->
geometry
().
x
()
/
10
);
x
*=
10
;
m_startPoint
=
x
;
this
->
setGeometry
(
x
,
this
->
y
(),
this
->
width
(),
this
->
height
());
}
int
x
=
(
this
->
geometry
().
x
()
/
10
);
x
*=
10
;
m_parent
->
mouseReleased
(
this
->
x
()
+
event
->
x
());
m_startPoint
=
x
;
this
->
setGeometry
(
x
,
this
->
y
(),
this
->
width
(),
this
->
height
());
}
int
KisAnimationFrame
::
getWidth
()
...
...
krita/plugins/extensions/dockers/animator/kis_animation_frame.h
View file @
ed4aaf35
...
...
@@ -71,7 +71,6 @@ private:
int
m_mousePressStartPoint
;
int
m_mousePressEndPoint
;
int
m_startPoint
;
bool
m_dragging
;
};
#endif // KIS_ANIMATION_FRAME_H
krita/plugins/extensions/dockers/animator/kis_layer_contents.cpp
View file @
ed4aaf35
...
...
@@ -78,12 +78,6 @@ void KisLayerContents::mouseReleaseEvent(QMouseEvent *event)
this
->
m_parent
->
setSelectedFrame
(
x
,
this
);
}
void
KisLayerContents
::
mouseReleased
(
int
x
)
{
x
=
x
-
(
x
%
10
);
m_parent
->
setSelectedFrame
(
x
,
this
);
}
void
KisLayerContents
::
mapFrame
(
int
frameNumber
,
KisAnimationFrame
*
frame
)
{
if
(
this
->
m_frames
.
contains
(
frameNumber
))
{
...
...
krita/plugins/extensions/dockers/animator/kis_layer_contents.h
View file @
ed4aaf35
...
...
@@ -55,8 +55,6 @@ public:
KisFrameBox
*
getParent
();
int
getLayerIndex
();
void
mouseReleased
(
int
x
);
protected:
void
paintEvent
(
QPaintEvent
*
event
);
void
mouseReleaseEvent
(
QMouseEvent
*
event
);
...
...
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