Skip to content

Commit eca4192

Browse files
committed
Modified the use CTRL and Meta
1 parent cc0c926 commit eca4192

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/com/tagtraum/perf/gcviewer/view/ModelChartImpl.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ private void maybePopup(MouseEvent e) {
186186
addMouseWheelListener(new MouseWheelListener() {
187187
@Override
188188
public void mouseWheelMoved(MouseWheelEvent e) {
189-
if ((e.getModifiersEx() & InputEvent.META_DOWN_MASK) != 0||(e.getModifiersEx() & InputEvent.CTRL_DOWN_MASK) != 0) {
189+
if (((e.getModifiersEx() & InputEvent.META_DOWN_MASK) != 0 && System.getProperty("os.name").contains("Mac OS X"))||(e.getModifiersEx() & InputEvent.CTRL_DOWN_MASK) != 0 && !System.getProperty("os.name").contains("Mac OS X")) {
190190
double pos = (double)(getHorizontalScrollBar().getValue()) / (double)(chart.getWidth());
191191
if (e.getWheelRotation() > 0 && getScaleFactor() < 100) {
192192
setScaleFactor((getScaleFactor()*1.2));

0 commit comments

Comments
 (0)