Skip to content
This repository was archived by the owner on Sep 3, 2019. It is now read-only.

Commit a9dca1f

Browse files
committed
Removed dependency to scratch offline code
1 parent 38b4ac1 commit a9dca1f

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

src/Scratch.as

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -136,9 +136,6 @@ public class Scratch extends Sprite {
136136

137137
public var logger:Log = new Log(16);
138138

139-
// Offline Queue
140-
private var offlineSystem:OfflineSystem = OfflineSystem.getInstance();
141-
142139
public function Scratch() {
143140
SVGTool.setStage(stage);
144141
loaderInfo.uncaughtErrorEvents.addEventListener(UncaughtErrorEvent.UNCAUGHT_ERROR, uncaughtErrorHandler);
@@ -1136,13 +1133,13 @@ public class Scratch extends Sprite {
11361133
'\n\nPlease do not distribute!', stage);
11371134
}
11381135

1136+
protected function onNewProject():void {}
1137+
11391138
protected function createNewProjectAndThen(callback:Function = null):void {
11401139
function clearProject():void {
11411140
startNewProject('', '');
11421141
setProjectName('Untitled');
1143-
var clientID:String = offlineSystem.getClientId();
1144-
var appOpenPacket:Packet = new Packet(clientID, "Untitled", 'project', 'create', offlineSystem.getCurrentLanguage(), null);
1145-
offlineSystem.enqueuePacket(appOpenPacket);
1142+
onNewProject();
11461143
topBarPart.refresh();
11471144
stagePart.refresh();
11481145
if (callback != null) callback();

0 commit comments

Comments
 (0)