reopen command line after error
This commit is contained in:
		
							parent
							
								
									e0bff54a82
								
							
						
					
					
						commit
						29f82d3a7f
					
				
					 3 changed files with 17 additions and 5 deletions
				
			
		| 
						 | 
				
			
			@ -10,6 +10,8 @@ export default class ConsoleFrame {
 | 
			
		|||
 | 
			
		||||
    this.element = element;
 | 
			
		||||
 | 
			
		||||
    this.errorShown = true;
 | 
			
		||||
 | 
			
		||||
    this.hide();
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			@ -21,6 +23,7 @@ export default class ConsoleFrame {
 | 
			
		|||
      text: text
 | 
			
		||||
    };
 | 
			
		||||
    messages.send(this.element.contentWindow, message);
 | 
			
		||||
    this.errorShown = false;
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  showError(text) {
 | 
			
		||||
| 
						 | 
				
			
			@ -31,6 +34,8 @@ export default class ConsoleFrame {
 | 
			
		|||
      text: text
 | 
			
		||||
    };
 | 
			
		||||
    messages.send(this.element.contentWindow, message);
 | 
			
		||||
    this.errorShown = true;
 | 
			
		||||
    this.element.blur();
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  showFrame() {
 | 
			
		||||
| 
						 | 
				
			
			@ -40,5 +45,10 @@ export default class ConsoleFrame {
 | 
			
		|||
  hide() {
 | 
			
		||||
    this.element.style.display = 'none';
 | 
			
		||||
    this.element.blur();
 | 
			
		||||
    this.errorShown = false;
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  isErrorShown() {
 | 
			
		||||
    return this.element.style.display === 'block' && this.errorShown;
 | 
			
		||||
  }
 | 
			
		||||
}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Reference in a new issue