Class: AsProject::WinUser
- Inherits:
-
User
- Object
- User
- AsProject::WinUser
show all
- Defined in:
- lib/path_finder.rb
Constant Summary
collapse
- @@LOCAL_SETTINGS =
"Local\ Settings"
- @@APPLICATION_DATA =
"Application\ Data"
Instance Method Summary
collapse
Methods inherited from User
#asproject_player_trust, #downloads, #file_exists?, #flash_player_config, #flash_player_config_content, #flash_player_log, #flash_player_trust, #get_or_create, #get_player_url
Constructor Details
Returns a new instance of WinUser.
428
429
430
431
432
433
434
435
436
|
# File 'lib/path_finder.rb', line 428
def initialize
super
@flash_player_7_url = "/pub/flashplayer/updaters/7/flash_player_update3_mx2004_win.zip"
@flash_player_8_url = "/pub/flashplayer/updaters/8/flash_player_update3_flash8_win.zip"
@flash_player_9_url = "/pub/flashplayer/updaters/9/sa_flashplayer_9_debug.exe"
@zip_target = File.join('Players', 'Debug', 'SAFlashPlayer.exe')
@win_asproject = 'AsProject'
end
|
Instance Method Details
#asproject_home ⇒ Object
478
479
480
481
482
483
484
|
# File 'lib/path_finder.rb', line 478
def asproject_home
if(library == home)
return super
end
ap_home = File.join(library, @win_asproject);
return get_or_create(ap_home)
end
|
#flash_player_home ⇒ Object
460
461
462
|
# File 'lib/path_finder.rb', line 460
def flash_player_home
return File.join(home, @@APPLICATION_DATA, 'Macromedia', 'Flash Player')
end
|
#flash_player_path(version) ⇒ Object
464
465
466
|
# File 'lib/path_finder.rb', line 464
def flash_player_path(version)
return File.join(asproject_home, 'players', 'FlashPlayer' + version.to_s + '.exe')
end
|
#home ⇒ Object
452
453
454
455
456
457
458
|
# File 'lib/path_finder.rb', line 452
def home
usr = super
if(usr.index "My Documents")
usr = File.dirname(usr)
end
return usr
end
|
#library ⇒ Object
468
469
470
471
472
473
474
475
476
|
# File 'lib/path_finder.rb', line 468
def library
application_data = File.join(home, @@LOCAL_SETTINGS, @@APPLICATION_DATA)
if(File.exists?(application_data))
return application_data
else
return super
end
end
|
#mxmlc ⇒ Object
448
449
450
|
# File 'lib/path_finder.rb', line 448
def mxmlc
return 'mxmlc.exe'
end
|
#remote_file_task(name, task) ⇒ Object
438
439
440
441
442
443
444
445
446
|
# File 'lib/path_finder.rb', line 438
def remote_file_task(name, task)
return WinRemoteFileTask.new(name, self) do |t|
if(task.win_url.nil?)
raise UsageError.new("There was a problem finding a target for #{task.name}, it doesn't appear as if this task was expected to run on your system...")
end
t.url = task.win_url
t. = task.
end
end
|