@@ -129,7 +129,7 @@ export default {
129
129
data: function () {
130
130
return {
131
131
appData: window.appData,
132
- startDebug: false ,
132
+ startDebug: window.ide.isDebuging ,
133
133
}
134
134
},
135
135
mounted() {
@@ -170,22 +170,15 @@ export default {
170
170
171
171
});
172
172
173
- window.api.receive('build-success', (data) => {
174
- if(data && self.startDebug){
175
- window.alertify.success('Hot reload! 🔥');
176
- window.api.send("update-project", {});
177
- }
178
- });
179
-
180
173
}, methods: {
181
- hotReload:function () {
182
- if (!this.startDebug){
174
+ hotReload: function () {
175
+ if (!this.startDebug) {
183
176
window.alertify.warning('Hot reload failed');
184
- }else{
177
+ } else {
185
178
this.save();
186
179
let data = {
187
180
isUpdate: true,
188
- command: './anubias-engine build ' + window.project.file ,
181
+ command: './anubias-engine build ' + window.project.file,
189
182
}
190
183
window.api.send("command", data);
191
184
}
@@ -203,10 +196,11 @@ export default {
203
196
return false;
204
197
}
205
198
this.$parent.TerminalShow();
206
- this.startDebug= true;
199
+ this.startDebug = true;
200
+ window.ide.isDebuging = true;
207
201
let data = {
208
202
isDebug: true,
209
- command: './anubias-engine build ' + window.project.file +' && cd build && flutter run' ,
203
+ command: './anubias-engine build ' + window.project.file + ' && cd build && flutter run',
210
204
}
211
205
window.api.send("command", data);
212
206
},
0 commit comments