git-svn-id: svn://db.shs.com.ru/libs@448 a8b55f48-bf90-11e4-a774-851b48703e85
This commit is contained in:
@@ -28,7 +28,7 @@ BlockView::~BlockView() {
|
||||
|
||||
void BlockView::_init() {
|
||||
grid_visible = grid_snap = pm_connect = navigation = m_connect = m_trace_with_buses = prev_tcb = minimap = true;
|
||||
mm_drag = moved = new_branch = new_bus = mm_cancel = iconnect = mm_copy = m_pin_mc = mm_thumb = move_bus_point = false;
|
||||
mm_drag = moved = new_branch = new_bus = mm_cancel = iconnect = mm_copy = m_pin_mc = mm_thumb = move_bus_point = wheel_zoom = false;
|
||||
match_bus = bus_from = 0;
|
||||
mm_ci = 0;
|
||||
hpin = 0;
|
||||
@@ -638,7 +638,7 @@ void BlockView::timerEvent(QTimerEvent * e) {
|
||||
|
||||
void BlockView::wheelEvent(QWheelEvent * e) {
|
||||
if (!navigation) return;
|
||||
if (e->modifiers().testFlag(Qt::ControlModifier)) {
|
||||
if (wheel_zoom || e->modifiers().testFlag(Qt::ControlModifier)) {
|
||||
double scl = 1. - e->delta() / 500.;
|
||||
//scale(scl, scl);
|
||||
if (!is_nav_anim || (nav_anim.state() != QPropertyAnimation::Running))
|
||||
@@ -654,7 +654,7 @@ void BlockView::wheelEvent(QWheelEvent * e) {
|
||||
animateNav(r);
|
||||
return;
|
||||
}
|
||||
QGraphicsView::wheelEvent(e);
|
||||
if (!wheel_zoom) QGraphicsView::wheelEvent(e);
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user