Class: JLDrill::FileProgressContext::FileProgress

Inherits:
Context::View
  • Object
show all
Defined in:
lib/jldrill/contexts/FileProgressContext.rb

Direct Known Subclasses

Gtk::FileProgress, Test::FileProgress

Instance Attribute Summary

Attributes inherited from Context::View

#context

Instance Method Summary collapse

Methods inherited from Context::View

#addView, #getWidget, #removeView, #removingViewFrom, #viewAddedTo

Constructor Details

#initialize(context) ⇒ FileProgress

Returns a new instance of FileProgress.



9
10
11
# File 'lib/jldrill/contexts/FileProgressContext.rb', line 9

def initialize(context)
    super(context)
end

Instance Method Details

#idle_add(&block) ⇒ Object

File loading is done during the idle times in the UI. This method must add a block to the idle loop in the UI. The block will return true when the file is finished loading. At that time the concrete class should call exit on the context.



23
24
25
# File 'lib/jldrill/contexts/FileProgressContext.rb', line 23

def idle_add(&block)
    # Define in the concrete class
end

#update(fraction) ⇒ Object

Update the progress display to the fraction



14
15
16
# File 'lib/jldrill/contexts/FileProgressContext.rb', line 14

def update(fraction)
    # Define in the concrete class
end