src/editmodes/drawmode.cc

changeset 824
6add2126e7ff
parent 823
1a2f593f0c02
child 825
f7649c9bfd9a
equal deleted inserted replaced
823:1a2f593f0c02 824:6add2126e7ff
119 } 119 }
120 120
121 return false; 121 return false;
122 } 122 }
123 123
124 void DrawMode::mouseReleased (MouseEventData const& data) 124 bool DrawMode::mouseReleased (MouseEventData const& data)
125 { 125 {
126 if (Super::mouseReleased (data))
127 return true;
128
126 if (_rectdraw) 129 if (_rectdraw)
127 { 130 {
128 if (m_drawedVerts.size() == 2) 131 if (m_drawedVerts.size() == 2)
129 { 132 {
130 endDraw (true); 133 endDraw (true);
131 return; 134 return true;
132 } 135 }
133 } 136 }
134 else 137 else
135 { 138 {
136 // If we have 4 verts, stop drawing. 139 // If we have 4 verts, stop drawing.
146 updateRectVerts(); 149 updateRectVerts();
147 } 150 }
148 } 151 }
149 152
150 addDrawnVertex (renderer()->position3D()); 153 addDrawnVertex (renderer()->position3D());
154 return true;
151 } 155 }

mercurial