Browse Source

Move files to the ui/ folder

customisations
alemart 11 months ago
parent
commit
ea15614653
4 changed files with 12 additions and 11 deletions
  1. 2
    2
      src/core/session.ts
  2. 6
    5
      src/core/viewport.ts
  3. 1
    1
      src/ui/gizmos.ts
  4. 3
    3
      src/ui/stats-panel.ts

+ 2
- 2
src/core/session.ts View File

29
 import { Viewport } from './viewport';
29
 import { Viewport } from './viewport';
30
 import { Settings } from './settings';
30
 import { Settings } from './settings';
31
 import { Stats } from './stats';
31
 import { Stats } from './stats';
32
-import { StatsPanel } from './stats-panel';
32
+import { StatsPanel } from '../ui/stats-panel';
33
+import { Gizmos } from '../ui/gizmos';
33
 import { Frame } from './frame';
34
 import { Frame } from './frame';
34
 import { Tracker } from '../trackers/tracker';
35
 import { Tracker } from '../trackers/tracker';
35
 import { Time } from './time';
36
 import { Time } from './time';
36
-import { Gizmos } from './gizmos';
37
 import { Source } from '../sources/source';
37
 import { Source } from '../sources/source';
38
 import { asap } from '../utils/asap';
38
 import { asap } from '../utils/asap';
39
 
39
 

+ 6
- 5
src/core/viewport.ts View File

27
 import { Nullable } from '../utils/utils';
27
 import { Nullable } from '../utils/utils';
28
 import { Resolution } from '../utils/resolution';
28
 import { Resolution } from '../utils/resolution';
29
 import { Utils } from '../utils/utils';
29
 import { Utils } from '../utils/utils';
30
-import { IllegalArgumentError, IllegalOperationError, NotSupportedError, AccessDeniedError } from '../utils/errors';
31
 import { HUD, HUDContainer } from './hud';
30
 import { HUD, HUDContainer } from './hud';
32
 import { AREvent, AREventTarget, AREventListener } from '../utils/ar-events';
31
 import { AREvent, AREventTarget, AREventListener } from '../utils/ar-events';
32
+import { IllegalArgumentError, IllegalOperationError, NotSupportedError, AccessDeniedError } from '../utils/errors';
33
 
33
 
34
 
34
 
35
 
35
 
758
     /** The canvases of the viewport */
758
     /** The canvases of the viewport */
759
     private readonly _canvases: ViewportCanvases;
759
     private readonly _canvases: ViewportCanvases;
760
 
760
 
761
-    /** Fullscreen utilities */
762
-    private readonly _fullscreen: ViewportFullscreenHelper;
763
-
764
     /** Resize helper */
761
     /** Resize helper */
765
     private readonly _resizer: ViewportResizer;
762
     private readonly _resizer: ViewportResizer;
766
 
763
 
767
     /** The current size of the underlying SpeedyMedia */
764
     /** The current size of the underlying SpeedyMedia */
768
     private _mediaSize: ViewportSizeGetter;
765
     private _mediaSize: ViewportSizeGetter;
769
 
766
 
767
+    /** Fullscreen utilities */
768
+    private readonly _fullscreen: ViewportFullscreenHelper;
769
+
770
 
770
 
771
 
771
 
772
 
772
 
791
         this._hud = new HUD(this._subContainer, settings.hudContainer);
791
         this._hud = new HUD(this._subContainer, settings.hudContainer);
792
         this._canvases = new ViewportCanvases(this._subContainer, initialSize, settings.canvas);
792
         this._canvases = new ViewportCanvases(this._subContainer, initialSize, settings.canvas);
793
 
793
 
794
-        this._fullscreen = new ViewportFullscreenHelper(this.container);
795
         this._resizer = new ViewportResizer(this);
794
         this._resizer = new ViewportResizer(this);
796
         this._resizer.setStrategyByName(this._style);
795
         this._resizer.setStrategyByName(this._style);
796
+
797
+        this._fullscreen = new ViewportFullscreenHelper(this.container);
797
     }
798
     }
798
 
799
 
799
     /**
800
     /**

src/core/gizmos.ts → src/ui/gizmos.ts View File

30
 import { Resolution } from '../utils/resolution';
30
 import { Resolution } from '../utils/resolution';
31
 import { Nullable, Utils } from '../utils/utils';
31
 import { Nullable, Utils } from '../utils/utils';
32
 import { IllegalArgumentError, IllegalOperationError, TrackingError } from '../utils/errors';
32
 import { IllegalArgumentError, IllegalOperationError, TrackingError } from '../utils/errors';
33
-import { Viewport } from './viewport';
33
+import { Viewport } from '../core/viewport';
34
 import { Tracker } from '../trackers/tracker';
34
 import { Tracker } from '../trackers/tracker';
35
 import { ImageTrackerOutput } from '../trackers/image-tracker/image-tracker';
35
 import { ImageTrackerOutput } from '../trackers/image-tracker/image-tracker';
36
 
36
 

src/core/stats-panel.ts → src/ui/stats-panel.ts View File

21
  */
21
  */
22
 
22
 
23
 import { SpeedySize } from 'speedy-vision/types/core/speedy-size';
23
 import { SpeedySize } from 'speedy-vision/types/core/speedy-size';
24
-import { Settings, PowerPreference } from './settings';
25
-import { Viewport } from './viewport';
24
+import { Settings, PowerPreference } from '../core/settings';
25
+import { Viewport } from '../core/viewport';
26
 import { Tracker } from '../trackers/tracker';
26
 import { Tracker } from '../trackers/tracker';
27
 import { Source } from '../sources/source';
27
 import { Source } from '../sources/source';
28
 import { Utils, Nullable } from '../utils/utils';
28
 import { Utils, Nullable } from '../utils/utils';
60
 
60
 
61
     /**
61
     /**
62
      * Constructor
62
      * Constructor
63
-     * @param parent parent element of the panel
63
+     * @param viewport Viewport
64
      */
64
      */
65
     constructor(viewport: Viewport)
65
     constructor(viewport: Viewport)
66
     {
66
     {

Loading…
Cancel
Save