-
Notifications
You must be signed in to change notification settings - Fork 28
/
Copy pathuninstall.html
222 lines (170 loc) · 7.52 KB
/
uninstall.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
<!DOCTYPE html>
<html>
<head>
<title>Michael Eskin's ABC Transcription Tools Uninstaller</title>
<meta charset="UTF-8">
<meta http-equiv="Content-Type" content="text/html">
<meta content="ABC player transpose jig reel folk folktab folktab.com" name="keywords">
<meta content="A simple-to-use ABC to standard music notation converter featuring tune play, transposition, tab generation, PDF export, and much more!" name="description">
<meta content="A simple-to-use ABC to standard music notation converter featuring tune play, transposition, tab generation, PDF export, and much more!" name="abstract">
<meta property="og:locale" content="en_US" />
<meta name="description" content="A simple-to-use ABC to standard music notation converter featuring tune play, transposition, tab generation, PDF export and much more!" />
<meta property="og:type" content="website" />
<meta property="og:title" content="Michael Eskin's ABC Transcription Tools Uninstaller" />
<meta property="og:description" content="A simple-to-use ABC to standard music notation converter featuring tune play, transposition, tab generation, PDF export and much more!" />
<meta property="og:url" content="https://michaeleskin.com/abctools/abctools.html" />
<meta property="og:site_name" content="Michael Eskin's ABC Transcription Tools Uninstaller" />
<meta property="og:image" content="https://michaeleskin.com/abctools/img/abc-icon.png" />
<meta name="msapplication-TileColor" content="#ffffff">
<meta name="msapplication-TileImage" content="https://michaeleskin.com/abctools/img/abc-ms-icon-144x144.png">
<meta name="theme-color" content="#ffffff">
<meta name="apple-mobile-web-app-title" content="ABC Tools Uninstaller">
<meta name="application-name" content="ABC Tools Uninstaller">
<link rel="apple-touch-icon" sizes="60x60" href="https://michaeleskin.com/abctools/img/abc-apple-icon-60x60.png">
<link rel="apple-touch-icon" sizes="72x72" href="https://michaeleskin.com/abctools/img/abc-apple-icon-72x72.png">
<link rel="apple-touch-icon" sizes="76x76" href="https://michaeleskin.com/abctools/img/abc-apple-icon-76x76.png">
<link rel="apple-touch-icon" sizes="114x114" href="https://michaeleskin.com/abctools/img/abc-apple-icon-114x114.png">
<link rel="apple-touch-icon" sizes="120x120" href="https://michaeleskin.com/abctools/img/abc-apple-icon-120x120.png">
<link rel="apple-touch-icon" sizes="144x144" href="https://michaeleskin.com/abctools/img/abc-apple-icon-144x144.png">
<link rel="apple-touch-icon" sizes="152x152" href="https://michaeleskin.com/abctools/img/abc-apple-icon-152x152.png">
<link rel="apple-touch-icon" sizes="180x180" href="https://michaeleskin.com/abctools/img/abc-apple-icon-180x180.png">
<link rel="icon" type="image/png" sizes="192x192" href="https://michaeleskin.com/abctools/img/abc-android-icon-192x192.png">
<link rel="icon" type="image/png" sizes="32x32" href="https://michaeleskin.com/abctools/img/abc-favicon-32x32.png">
<link rel="icon" type="image/png" sizes="96x96" href="https://michaeleskin.com/abctools/img/abc-favicon-96x96.png">
<link rel="icon" type="image/png" sizes="16x16" href="https://michaeleskin.com/abctools/img/abc-favicon-16x16.png">
<style>
.btn {
--color: #000000;
--background-color: #d8d8d8;
--border-color: darken(#d8d8d8, 7.5%);
color: var(--color);
font-family: helvetica !important;
font-size: 11pt !important;
background-color: var(--background-color);
padding: 0.7rem 0.7rem;
padding-top: 0.8rem;
border: solid 1px var(--border-color);
outline: none;
position: relative;
border-radius: 0.5rem;
user-select: none;
box-shadow: 0 0.1rem 0.1rem rgba(0, 0, 0, 0.25), 0 -0.1rem 0.5rem rgba(0, 0, 0, 0.1) inset;
-webkit-appearance:none;
}
.btn:after {
content: "";
background-color: #ffffff;
width: 75%;
height: 12.5%;
position: absolute;
top: 0.15rem;
left: 12.5%;
border-radius: 50%;
filter: blur(0.15rem);
}
.btn:active {
box-shadow: 0 0 0 rgba(0, 0, 0, 0.4), 0 0.4rem 1rem rgba(0, 0, 0, 0.3) inset;
}
.btn:active:after {
opacity: 0;
}
.btn-info {
--color: black;
--background-color: #FFDDDD;
}
.btn-info:active {
--color: #ececec;
}
@media (hover: hover) {
.unregistersw:hover{
background: palegreen;
}
}
</style>
<script>
//
// Delete all the databases
//
function delete_all_DB(){
// Delete legacy reverb impulses database
const DBDeleteRequest0 = window.indexedDB.deleteDatabase("reverb_impulses");
DBDeleteRequest0.onerror = (event) => {
console.log("Error deleting reverb_impulses database.");
};
DBDeleteRequest0.onsuccess = (event) => {
console.log("reverb_impulses database deleted successfully");
};
setTimeout(function(){
const DBDeleteRequest1 = window.indexedDB.deleteDatabase("reverb_impulses_all");
DBDeleteRequest1.onerror = (event) => {
console.log("Error deleting reverb_impulses_all database.");
};
DBDeleteRequest1.onsuccess = (event) => {
console.log("reverb_impulses_all database deleted successfully");
};
},500);
setTimeout(function(){
const DBDeleteRequest2 = window.indexedDB.deleteDatabase("tune_search_database");
DBDeleteRequest2.onerror = (event) => {
console.log("Error deleting tune_search_database database.");
};
DBDeleteRequest2.onsuccess = (event) => {
console.log("tune_search_database database deleted successfully");
};
},500);
setTimeout(function(){
const DBDeleteRequest3 = window.indexedDB.deleteDatabase("samples");
DBDeleteRequest3.onerror = (event) => {
console.log("Error deleting samples database.");
};
DBDeleteRequest3.onsuccess = (event) => {
console.log("samples database deleted successfully");
};
},500);
}
function unregisterServiceWorker(){
var alertShown = false;
// Unregister service worker
navigator.serviceWorker.getRegistrations()
.then(registrations => {
if (registrations.length == 0){
alert("No installed ABC Transcription Tools found.");
}
else
{
registrations.map(r => {
if (r.scope.indexOf("abctools") != -1){
console.log("Unregistering ABC Transcription Tools service worker at scope: "+r.scope);
r.unregister();
}
if (!alertShown){
alertShown = true;
alert("ABC Transcription Tools have been uninstalled.");
}
});
}
});
}
function deleteCaches(){
caches.keys().then((keys) => {
return Promise.all(
keys.map((key) => {if ((key.indexOf("abctoolscache") != -1) || (key.indexOf("cache-20") != -1)){caches.delete(key)}})
);
})
}
function doUninstall(){
// Delete the databases
delete_all_DB();
// Delete all caches
deleteCaches();
// Unregister the service worker and delete the service worker cache
unregisterServiceWorker();
}
</script>
</head>
<body>
<p style="text-align:center;font-size:18pt;font-family:helvetica;margin-top:36px">Uninstall the ABC Transcription Tools</p>
<p style="text-align:center;font-size:14pt;font-family:helvetica;margin-top:48px">Click the button below to uninstall the tools from your browser and delete all cached resources.</p>
<p style="text-align:center;font-size:14pt;font-family:helvetica;margin-top:48px"><input id="unregistersw" class="btn btn-info unregistersw" onclick="doUninstall();" type="button" value="Click here to Uninstall the ABC Transcription Tools from your Browser">
</body>
</html>