Class List Method List File List

# Class: OSX::NSApplication::RBCCTemporaryDelegate Private

Inherits:
  OSX::NSObject
  - Object
  - OSX::NSObject
  - OSX::NSApplication::RBCCTemporaryDelegate
  show all
Defined in:
  src/ruby/osx/objc/cocoa_macros_appkit.rb

## Overview

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

A delegate class in NSApplication.run_with_temp_app.

## Instance Attribute Summary (collapse)

- - (Object) proc writeonly private
- - (Object) terminate writeonly private

## Instance Method Summary (collapse)

- - (Object) applicationDidFinishLaunching(sender) private

## Instance Attribute Details

### - (`Object`) proc=(value) (writeonly)

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

    16
    17
    18
    # File 'src/ruby/osx/objc/cocoa_macros_appkit.rb', line 16

    def proc=(value)
      @proc = value
    end

### - (`Object`) terminate=(value) (writeonly)

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

    16
    17
    18
    # File 'src/ruby/osx/objc/cocoa_macros_appkit.rb', line 16

    def terminate=(value)
      @terminate = value
    end

## Instance Method Details

### - (`Object`) applicationDidFinishLaunching(sender)

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    # File 'src/ruby/osx/objc/cocoa_macros_appkit.rb', line 18

    def applicationDidFinishLaunching(sender)
    	begin
    	  @proc.call
    	rescue Exception => err
    	  warn "#{err.message} (#{err.class})\n"
    	  warn err.backtrace.join("\n    ")
    	ensure
    	  OSX::NSApplication.sharedApplication.terminate(self) if @terminate
    	end
    end