Skip to content

Commit e031e66

Browse files
committed
Merge branch 'v8' of https://github.com/GleapSDK/JavaScript-SDK into v8
2 parents 9a08c8f + 542d873 commit e031e66

File tree

11 files changed

+18
-78
lines changed

11 files changed

+18
-78
lines changed

build/index.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

demo/main.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
const Gleap = window.Gleap;
22

3-
Gleap.disableConsoleLogOverwrite();
4-
3+
//Gleap.setFrameUrl("http://0.0.0.0:3001");
4+
//Gleap.setApiUrl("http://0.0.0.0:9000");
55
Gleap.initialize("DUPaIr7s689BBblcFI4pc5aBgYJTm7Sc");
66
//Gleap.setEnvironment("dev");
77

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "gleap",
3-
"version": "8.5.4",
3+
"version": "8.5.5",
44
"main": "build/index.js",
55
"scripts": {
66
"start": "webpack serve",

published/8.5.4/index.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

published/8.5.5/index.js

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

published/latest/index.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/GleapMarkerManager.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -121,14 +121,14 @@ export default class GleapMarkerManager {
121121
}
122122

123123
mouseMoveEventHandler(e) {
124-
const x = e.pageX - document.documentElement.scrollLeft;
125-
const y = e.pageY - document.documentElement.scrollTop;
124+
const x = e.clientX;
125+
const y = e.clientY;
126126
this.setMouseMove(x, y);
127127
}
128128

129129
touchMoveEventHandler(e) {
130-
const x = e.touches[0].pageX - document.documentElement.scrollLeft;
131-
const y = e.touches[0].pageY - document.documentElement.scrollTop;
130+
const x = e.touches[0].clientX;
131+
const y = e.touches[0].clientY;
132132
this.setMouseMove(x, y);
133133
}
134134

src/GleapNotificationBadge.js

Lines changed: 0 additions & 46 deletions
This file was deleted.

src/GleapNotificationManager.js

Lines changed: 2 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import Gleap, {
44
GleapFrameManager,
55
GleapSession,
66
} from "./Gleap";
7-
import GleapNotificationBadge from './GleapNotificationBadge';
87
import { loadFromGleapCache, saveToGleapCache } from "./GleapHelper";
98
import { loadIcon } from "./UI";
109

@@ -13,7 +12,6 @@ export default class GleapNotificationManager {
1312
notifications = [];
1413
unreadCount = 0;
1514
unreadNotificationsKey = "unread-notifications";
16-
badgeManager = null;
1715
isTabActive = true;
1816
showNotificationBadge = true;
1917

@@ -27,24 +25,11 @@ export default class GleapNotificationManager {
2725
}
2826

2927
constructor() {
30-
if (typeof window !== "undefined") {
31-
try {
32-
this.badgeManager = new GleapNotificationBadge();
33-
this.badgeManager.value = 0;
34-
} catch (exp) {
35-
this.badgeManager = null;
36-
}
37-
}
28+
3829
}
3930

4031
updateTabBarNotificationCount() {
41-
if (this.badgeManager) {
42-
if (this.showNotificationBadge) {
43-
this.badgeManager.value = this.unreadCount;
44-
} else {
45-
this.badgeManager.value = 0;
46-
}
47-
}
32+
4833
}
4934

5035
/**

src/ScreenDrawer.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -184,14 +184,14 @@ export class ScreenDrawer {
184184
getMousePosition(e) {
185185
if (e.touches && e.touches.length > 0) {
186186
return {
187-
x: e.touches[0].pageX,
188-
y: e.touches[0].pageY,
187+
x: e.touches[0].clientX,
188+
y: e.touches[0].clientY,
189189
};
190190
}
191191

192192
return {
193-
x: e.pageX,
194-
y: e.pageY,
193+
x: e.clientX,
194+
y: e.clientY,
195195
};
196196
}
197197

0 commit comments

Comments
 (0)