Class: ScreenRecorder::Window
- Includes:
- Screenshot
- Defined in:
- lib/screen-recorder/window.rb
Overview
Constant Summary
Constants inherited from Common
Instance Attribute Summary
Attributes inherited from Common
Class Method Summary collapse
-
.fetch_title(process_name) ⇒ Array
Returns a list of available window titles for the given process (application) name.
Instance Method Summary collapse
-
#initialize(title:, output:, advanced: {}) ⇒ Window
constructor
Window recording mode.
Methods included from Screenshot
Methods inherited from Common
Constructor Details
#initialize(title:, output:, advanced: {}) ⇒ Window
Window recording mode.
10 11 12 13 14 |
# File 'lib/screen-recorder/window.rb', line 10 def initialize(title:, output:, advanced: {}) raise 'Window recording is only supported on Microsoft Windows.' unless OS.windows? super(input: %("title=#{title}"), output: output, advanced: advanced) end |
Class Method Details
.fetch_title(process_name) ⇒ Array
Returns a list of available window titles for the given process (application) name.
25 26 27 28 |
# File 'lib/screen-recorder/window.rb', line 25 def fetch_title(process_name) ScreenRecorder.logger.debug "Retrieving window title from '#{process_name}'" window_title_for process_name end |