This repository was archived by the owner on Apr 29, 2021. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +10
-2
lines changed
Expand file tree Collapse file tree 3 files changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -31,6 +31,10 @@ public void Update() {
3131 public void OnEnable ( ) {
3232 this . _lastDevicePixelRatio = GameViewUtil . getGameViewDevicePixelRatio ( ) ;
3333 }
34+
35+ public void onViewMetricsChanged ( ) {
36+
37+ }
3438
3539 public float devicePixelRatio {
3640 get { return this . _lastDevicePixelRatio ; }
Original file line number Diff line number Diff line change @@ -25,6 +25,7 @@ public interface DisplayMetrics {
2525 void OnEnable ( ) ;
2626 void OnGUI ( ) ;
2727 void Update ( ) ;
28+ void onViewMetricsChanged ( ) ;
2829
2930 float devicePixelRatio { get ; }
3031
@@ -46,11 +47,14 @@ public void OnGUI() {
4647 }
4748
4849 public void Update ( ) {
50+
51+ }
52+
53+ public void onViewMetricsChanged ( ) {
4954 //view metrics marks dirty
5055 this . _viewMetrics = null ;
5156 }
5257
53-
5458 public float devicePixelRatio {
5559 get {
5660 if ( this . _devicePixelRatio > 0 ) {
Original file line number Diff line number Diff line change @@ -130,7 +130,7 @@ bool _mouseEntered {
130130
131131 void _handleViewMetricsChanged ( string method , List < JSONNode > args ) {
132132 this . _windowAdapter . onViewMetricsChanged ( ) ;
133- this . _displayMetrics . Update ( ) ;
133+ this . _displayMetrics . onViewMetricsChanged ( ) ;
134134 }
135135
136136 protected override void OnEnable ( ) {
You can’t perform that action at this time.
0 commit comments