Skip to content

Commit

Permalink
disable framerate text selection (#377)
Browse files Browse the repository at this point in the history
* Update FramerateCategory.hx

* Update MemoryCounter.hx

* Update FramerateCounter.hx

* Update CodenameBuildField.hx
  • Loading branch information
DixNutzzz authored Sep 6, 2024
1 parent 16fa304 commit d9968a8
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,6 @@ class CodenameBuildField extends TextField {
autoSize = LEFT;
multiline = wordWrap = false;
text = 'Codename Engine ${Main.releaseCycle}\nCommit ${GitCommitMacro.commitNumber} (${GitCommitMacro.commitHash})';
selectable = false;
}
}
3 changes: 2 additions & 1 deletion source/funkin/backend/system/framerate/FramerateCategory.hx
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ class FramerateCategory extends Sprite {
label.x = 0;
label.y = 0;
label.defaultTextFormat = new TextFormat(Framerate.fontName, label == this.title ? 18 : 12, -1);
label.selectable = false;
addChild(label);
}
this.title.text = title;
Expand All @@ -49,4 +50,4 @@ class FramerateCategory extends Sprite {
bgSprite.scaleX = width;
bgSprite.scaleY = height;
}
}
}
3 changes: 2 additions & 1 deletion source/funkin/backend/system/framerate/FramerateCounter.hx
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ class FramerateCounter extends Sprite {
label.text = "FPS";
label.multiline = label.wordWrap = false;
label.defaultTextFormat = new TextFormat(Framerate.fontName, label == fpsNum ? 18 : 12, -1);
label.selectable = false;
addChild(label);
}
}
Expand All @@ -35,4 +36,4 @@ class FramerateCounter extends Sprite {
fpsLabel.x = fpsNum.x + fpsNum.width;
fpsLabel.y = (fpsNum.y + fpsNum.height) - fpsLabel.height;
}
}
}
3 changes: 2 additions & 1 deletion source/funkin/backend/system/framerate/MemoryCounter.hx
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ class MemoryCounter extends Sprite {
label.text = "FPS";
label.multiline = label.wordWrap = false;
label.defaultTextFormat = new TextFormat(Framerate.fontName, 12, -1);
label.selectable = false;
addChild(label);
}
memoryPeakText.alpha = 0.5;
Expand All @@ -40,4 +41,4 @@ class MemoryCounter extends Sprite {

memoryPeakText.x = memoryText.x + memoryText.width;
}
}
}

0 comments on commit d9968a8

Please sign in to comment.