MCPcopy Index your code
hub / github.com/material-shell/material-shell / disable

Method disable

src/extension.ts:171–204  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

169 }
170
171 override disable(): void {
172 log('-----------------');
173 log('DISABLE EXTENSION');
174 log('-----------------');
175 if (Main.sessionMode.currentMode === 'unlock-dialog') {
176 this.locked = true;
177 this.layout?.panel.disable();
178 } else {
179 this.disableInProgress = true;
180 Async.clearAllPendingTimeout();
181 if (!modules) return;
182 if (_closingId !== undefined) {
183 global.display.disconnect(_closingId);
184 }
185 this.emit('extension-disable');
186 modules.reverse().forEach((module) => {
187 module.destroy();
188 });
189 this.tooltipManager?.destroy();
190 this.layoutManager?.destroy();
191 this.msWorkspaceManager?.destroy();
192 this.msWindowManager?.destroy();
193
194 this.layout?.destroy();
195 this.msThemeManager?.destroy();
196 disableIncompatibleExtensionsModule.destroy();
197 this.stateManager?.destroy();
198 this.loaded = false;
199 delete this.disableInProgress;
200 }
201 log('---------------------');
202 log('END DISABLE EXTENSION');
203 log('---------------------');
204 }
205
206 load(disconnect: boolean) {
207 log('----------------');

Callers

nothing calls this directly

Calls 6

emitMethod · 0.95
logFunction · 0.85
reverseMethod · 0.80
disconnectMethod · 0.65
destroyMethod · 0.65

Tested by

no test coverage detected