Changes between Version 23 and Version 24 of HTMLGfx


Ignore:
Timestamp:
Jan 17, 2015, 2:35:15 PM (10 years ago)
Author:
romw
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • HTMLGfx

    v23 v24  
    8585        switch_to_url = running_url
    8686
    87     if ((is_vbox_job && api_port) && (switch_to_url is empty))
    88         switch_to_url  = "http://localhost:" + api_port + "/";
     87    if ((is_vbox_job && webapi_port) && (switch_to_url is empty))
     88        switch_to_url  = "http://localhost:" + webapi_port + "/";
     89
     90    if (switch_to_url is empty)
     91        switch_to_url  = "http://localhost:" + webserver_port + "/api/static/index.html";
    8992}}}
    9093
     
    123126the boinc_write_graphics_status() BOINC API.
    124127
    125 Reference: [BasicApi#GraphicsStatus boinc_graphics_status.xml]
     128Reference: [BasicApi#GraphicsStatus graphics_status.xml]
    126129
    127130=== Vboxwrapper WebAPI Port ===
     
    133136Reference: [VboxApps#RemoteDesktopstatefile vbox_remote_desktop.xml]
    134137
    135 === !JavaScript Extension on Windows ===
    136 Currently HTMLGfx can pass information to the HTML DOM via the 'window.external' extension.
    137 
    138 ==== Methods ====
    139 
    140 || Name                       || Returns || Description ||
    141 || log(string)                || void    || Logs a message to stderrgfx.txt ||
    142 || debug(string)              || void    || Logs a message with a category of 'DEBUG' to stderrgfx.txt ||
    143 || info(string)               || void    || Logs a message with a category of 'INFO' to stderrgfx.txt ||
    144 || warn(string)               || void    || Logs a message with a category of 'WARNING' to stderrgfx.txt ||
    145 || error(string)              || void    || Logs a message with a category of 'ERROR' to stderrgfx.txt ||
    146 || isStateUpdated()           || Boolean || Returns true if it is time to refresh all the state in the UI ||
    147 || resetStateUpdate(Boolean)  || void    || Resets the state update flag to the given value ||
    148 
    149 ==== Properties ====
    150 
    151 || Name                  || Data Type || Description ||
    152 || appName               || string    || ||
    153 || appVersion            || long      || ||
    154 || wuName                || string    || ||
    155 || resName               || string    || ||
    156 || teamName              || string    || ||
    157 || userName              || string    || ||
    158 || userCreditTotal       || float     || ||
    159 || userCreditAverage     || float     || ||
    160 || hostCreditTotal       || float     || ||
    161 || hostCreditAverage     || float     || ||
    162 || scrsaveMode           || Boolean   || Was the graphics application launched in screensaver mode    ||
    163 || suspended             || Boolean   || Whether the task is currently suspended ||
    164 || networkSuspended      || Boolean   || Should the UI suspend Internet activity ||
    165 || exiting               || Boolean   || Should the UI prepare to exit ||
    166 || exitTimeout           || float     || ||
    167 || cpuTime               || float     || ||
    168 || elapsedTime           || float     || ||
    169 || fractionDone          || float     || ||
    170 || vboxJob               || Boolean   || Is this task a vboxwrapper task? ||
    171 || rdpPort               || long      || ||
    172 || apiPort               || long      || ||
    173 
    174 
    175 ==== Examples ====
    176 Example of refreshing the state of various controls:
    177 {{{
    178     refresh() {
    179         if (window.external.isStateUpdated()) {
    180             window.external.resetStateUpdate(false);
    181             username = window.external.userName;
    182             teamname = window.external.teamName;
    183         }
    184         fractiondone = window.external.fractionDone;
    185     }
    186 }}}
    187 
    188138== Example HTML Page ==
    189139
    190140Here is a link to a working HTML page that is embedded within the HTMLGfx app in case the boinc_graphics.xml file is missing.
    191141
    192 Reference: [http://boinc.berkeley.edu/gitweb/?p=boinc-v2.git;a=blob;f=samples/gfx_html/res/default_win.htm;hb=HEAD default_win.htm]
     142Reference: [http://boinc.berkeley.edu/gitweb/?p=boinc-v2.git;a=tree;f=samples/gfx_html/templates;hb=master HTML Source Files]
    193143
    194144== Precompiled Binaries ==