Class: Textbringer::Server::FrontObject
- Inherits:
-
Object
- Object
- Textbringer::Server::FrontObject
- Defined in:
- lib/textbringer/commands/server.rb,
sig/lib/textbringer/commands/server.rbs
Instance Method Summary collapse
Instance Method Details
#eval(s) ⇒ String
84 85 86 87 88 |
# File 'lib/textbringer/commands/server.rb', line 84 def eval(s) with_redisplay do Controller.current.instance_eval(s).inspect end end |
#visit_file(filename, wait: true) ⇒ Symbol
90 91 92 93 94 95 96 97 |
# File 'lib/textbringer/commands/server.rb', line 90 def visit_file(filename, wait: true) queue = Queue.new if wait with_redisplay do find_file(filename) Buffer.current[:client_wait_queue] = queue if wait end queue.deq if wait end |
#with_redisplay ⇒ String #with_redisplay ⇒ Thread::Queue
101 102 103 104 105 106 107 108 109 |
# File 'lib/textbringer/commands/server.rb', line 101 def with_redisplay foreground! do begin yield ensure Window.redisplay end end end |