/[freeride]/freeride/freebase/core.rb
ViewVC logotype

Diff of /freeride/freebase/core.rb

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.6 by curthibbs, Mon May 27 08:44:54 2002 UTC revision 1.7 by ljulliar, Fri Jun 14 14:15:06 2002 UTC
# Line 3  Line 3 
3  # $Id$  # $Id$
4  #  #
5  # Authors:  Rich Kilmer <rich@infoether.com>  # Authors:  Rich Kilmer <rich@infoether.com>
6  # Contributors:  # Contributors:
7    #  - Laurent Julliard <laurent AT moldus DOT org)
8  #  #
9  # This file is part of the FreeRIDE project  # This file is part of the FreeRIDE project
10  #  #
# Line 14  Line 15 
15  # Copyright (c) 2001 Rich Kilmer. All rights reserved.  # Copyright (c) 2001 Rich Kilmer. All rights reserved.
16  #  #
17    
18    require 'rbconfig'
19    
20  module FreeBASE  module FreeBASE
21        
22    ##    ##
# Line 21  module FreeBASE Line 24  module FreeBASE
24    # the installed plugins.    # the installed plugins.
25    #    #
26    class Core    class Core
27      
28        include Config
29    
30      ##      ##
31      # Starts the Core service.  This method blocks until shutdown.      # Starts the Core service.  This method blocks until shutdown.
32      #      #
# Line 48  module FreeBASE Line 53  module FreeBASE
53        load_setup        load_setup
54        @bus["/log/info"] << "--- #{@properties['config/product_name']} Started on #{Time.now.to_s}"        @bus["/log/info"] << "--- #{@properties['config/product_name']} Started on #{Time.now.to_s}"
55                
56        # --- BEGIN HACK (part 1) ---  
57        # the following code is a temporary workaround for a problem using FXRuby in        if (Config::CONFIG['os_host'] == 'mswin32')
58        # an mswin build of Ruby. This should be removed once that problem has been fixed.          # --- BEGIN HACK (part 1) ---
59                  # the following code is a temporary workaround for a problem using FXRuby in
60        # default to a do-nothing message pump          # an mswin build of Ruby. This should be removed once that problem has been fixed.
61        @bus["/system/ui/messagepump"].set_proc do sleep(0.5) end          # also see plugins/System_GuiRenderFox/foxhacks.rb
62        # --- END HACK ---  
63            # default to a do-nothing message pump
64            @bus["/system/ui/messagepump"].set_proc do sleep(0.5) end
65            # --- END HACK (part 1) ---
66          end
67    
68        @bus["/system/state/all_plugins_loaded"].data = false;        @bus["/system/state/all_plugins_loaded"].data = false;
69                          load_plugins                          load_plugins
70        @bus["/system/state/all_plugins_loaded"].data = true;        @bus["/system/state/all_plugins_loaded"].data = true;
71    
72                          # --- BEGIN HACK (part 2) ---        if (Config::CONFIG['os_host'] == 'mswin32')
73        while true do          # --- BEGIN HACK (part 2) ---
74          @bus["/system/ui/messagepump"].call()          while true do
75          sleep(0.1)            @bus["/system/ui/messagepump"].call()
76              sleep(0.1)
77            end
78            # --- END HACK (part 2) ---
79          else
80            tui = Thread.new {
81              @bus["/system/ui/messagepump"].call()
82            }
83            tui.join
84        end        end
85        # --- END HACK ---  
         
86      end      end
87            
88      ##      ##

Legend:
Removed from v.1.6  
changed lines
  Added in v.1.7

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26