MCPcopy Create free account
hub / github.com/candybox2/candybox2.github.io / setScrolling

Method setScrolling

code/main/RenderLocation.ts:41–50  ·  view source on GitHub ↗
(scrolling: boolean, defaultScroll: number = 0)

Source from the content-addressed store, hash-verified

39 }
40
41 public setScrolling(scrolling: boolean, defaultScroll: number = 0): void{
42 // If the scrolling is different
43 if(this.scrolling != scrolling){
44 this.scrolling = scrolling;
45
46 // We initialize or stop scrolling, depending on the new scrolling value
47 if(this.scrolling) this.initScrolling(defaultScroll);
48 else this.stopScrolling();
49 }
50 }
51
52 // Public getters
53 public getScroll(): number{

Callers 2

constructorMethod · 0.95
displayAreaMethod · 0.80

Calls 2

initScrollingMethod · 0.95
stopScrollingMethod · 0.95

Tested by

no test coverage detected