Skip to content

Commit f8783aa

Browse files
committed
Fixing linting issues
Signed-off-by: Aleksandr Motsjonov <[email protected]>
1 parent 4359a2b commit f8783aa

File tree

2 files changed

+8
-7
lines changed

2 files changed

+8
-7
lines changed

src/iv/imageviewer.cpp

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2015,7 +2015,7 @@ ImageViewer::zoomIn(bool smooth)
20152015
float current_zoom = zoom();
20162016
if (current_zoom >= 64)
20172017
return;
2018-
2018+
20192019
float newzoom = ceil2f(current_zoom);
20202020

20212021
this->zoomToCursor(newzoom, smooth);
@@ -2028,11 +2028,11 @@ ImageViewer::zoomOut(bool smooth)
20282028
IvImage* img = cur();
20292029
if (!img)
20302030
return;
2031-
2031+
20322032
float current_zoom = zoom();
20332033
if (current_zoom <= 1.0f / 64)
20342034
return;
2035-
2035+
20362036
float newzoom = floor2f(current_zoom);
20372037

20382038
this->zoomToCursor(newzoom, smooth);
@@ -2051,10 +2051,11 @@ ImageViewer::zoomToCursor(float newzoom, bool smooth)
20512051
float yoffset = yc - ym;
20522052

20532053
float maxzoomratio = std::max(oldzoom / newzoom, newzoom / oldzoom);
2054-
int nsteps = smooth ? (int)OIIO::clamp(20 * (maxzoomratio - 1), 2.0f, 10.0f) : 1;
2054+
int nsteps = smooth ? (int)OIIO::clamp(20 * (maxzoomratio - 1), 2.0f, 10.0f)
2055+
: 1;
20552056
for (int i = 1; i <= nsteps; ++i) {
2056-
float a = (float)i / (float)nsteps; // Interpolation amount
2057-
float z = OIIO::lerp(oldzoom, newzoom, a);
2057+
float a = (float)i / (float)nsteps; // Interpolation amount
2058+
float z = OIIO::lerp(oldzoom, newzoom, a);
20582059
float zoomratio = z / oldzoom;
20592060
view(xm + xoffset / zoomratio, ym + yoffset / zoomratio, z, false);
20602061
if (i != nsteps) {

src/iv/ivgl.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1212,7 +1212,7 @@ IvGL::mousePressEvent(QMouseEvent* event)
12121212
{
12131213
remember_mouse(event->pos());
12141214
int mousemode = m_viewer.mouseModeComboBox->currentIndex();
1215-
bool Alt = (event->modifiers() & Qt::AltModifier);
1215+
bool Alt = (event->modifiers() & Qt::AltModifier);
12161216
m_drag_button = event->button();
12171217
if (!m_mouse_activation) {
12181218
switch (event->button()) {

0 commit comments

Comments
 (0)