Remove XUL opensrf.math Client
authorJason Boyer <JBoyer@equinoxOLI.org>
Tue, 17 Aug 2021 18:01:55 +0000 (14:01 -0400)
committerChris Sharp <csharp@georgialibraries.org>
Fri, 24 Sep 2021 18:11:39 +0000 (14:11 -0400)
Signed-off-by: Jason Boyer <JBoyer@equinoxOLI.org>
Signed-off-by: Jason Stephenson <jason@sigio.com>
Signed-off-by: Chris Sharp <csharp@georgialibraries.org>
13 files changed:
Makefile.am
configure.ac
examples/math_xul_client/Makefile.in [deleted file]
examples/math_xul_client/install.js [deleted file]
examples/math_xul_client/math/content/conf/client_config.xml [deleted file]
examples/math_xul_client/math/content/contents.rdf [deleted file]
examples/math_xul_client/math/content/math.xul [deleted file]
examples/math_xul_client/math/content/math_app.js [deleted file]
examples/math_xul_client/math/content/math_overlay.xul [deleted file]
examples/math_xul_client/math/locale/en-US/contents.rdf [deleted file]
examples/math_xul_client/math/locale/en-US/math.dtd [deleted file]
examples/math_xul_client/math/skin/contents.rdf [deleted file]
examples/math_xul_client/math/skin/math.css [deleted file]

index 4846ddd..bf1effe 100644 (file)
@@ -55,9 +55,7 @@ EXAMPLES_FILES = @srcdir@/examples/fieldmapper2cdbi.xsl \
                                 @srcdir@/examples/math_bench.pl \
                                 @srcdir@/examples/math_client.py \
                                 @srcdir@/examples/multisession-test.pl \
-                                @srcdir@/examples/srfsh_config.xsd \
-                                @srcdir@/examples/math_xul_client/math \
-                                @srcdir@/examples/math_xul_client/install.js
+                                @srcdir@/examples/srfsh_config.xsd
 
 strn_compat_FILES = @srcdir@/src/ports/strn_compat/strndup.c \
                                        @srcdir@/src/ports/strn_compat/strndup.h \
index a643bfd..21963b0 100644 (file)
@@ -317,7 +317,6 @@ if test "x$OSRF_INSTALL_CORE" = "xtrue"; then
        #------------------------------------
 
        AC_CONFIG_FILES([doc/dokuwiki-doc-stubber.pl
-                        examples/math_xul_client/Makefile
                         examples/math_bench.pl
                         examples/multisession-test.pl
                         src/c-apps/Makefile
@@ -330,7 +329,7 @@ if test "x$OSRF_INSTALL_CORE" = "xtrue"; then
                         src/router/Makefile
                         src/srfsh/Makefile
                         src/websocket-stdio/Makefile
-             tests/Makefile
+                        tests/Makefile
                         bin/opensrf-perl.pl
                         bin/osrf_config])
 fi
diff --git a/examples/math_xul_client/Makefile.in b/examples/math_xul_client/Makefile.in
deleted file mode 100644 (file)
index 41ac95c..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-all: clean client
-       @echo
-
-client:
-       @echo We need the OpenSRF javascript code...
-       mkdir math/content/OpenSRF/
-       cp ../../src/javascript/*.js math/content/OpenSRF/
-       @echo We need a log directory...
-       mkdir math/content/log
-       touch math/content/log/preserve.directory.when.zipping
-       @echo We also need a math/content/conf/client_config.xml pointing to a running OpenSRF Math application.
-       @echo Then we package this into a Mozilla XPI file...
-       zip -q -r math.xpi install.js math/
-       @echo After installing the XPI, use the chrome URL:
-       @echo chrome://math/content/
-
-clean:
-       @echo Removing the OpenSRF javascript code, the log directory, and math.xpi...
-       rm -rf math/content/OpenSRF/ math/content/log math.xpi
diff --git a/examples/math_xul_client/install.js b/examples/math_xul_client/install.js
deleted file mode 100644 (file)
index 0b10d3d..0000000
+++ /dev/null
@@ -1,98 +0,0 @@
-// ripped from Evergreen installation file
-
-/* We'll want to make this more flexible later */
-
-install();
-
-// ----------------------------------------------------------------------------
-// Performs the install
-// ----------------------------------------------------------------------------
-function install() {
-
-       // ----------------------------------------------------------------------------
-       var _authors = "PINES";
-       var _package = "math";
-       var _packg_l = "math";
-       var _version = "0.0.1";
-       // ----------------------------------------------------------------------------
-
-       var err; // track the error
-
-       err = initInstall( _package, "/"+_authors+"/"+_package, _version );
-       if( err != 0 ) { return warn( "initInstall: " + err );}
-
-       // ----------------------------------------------------------------------------
-       // Discovers the path to the install directory
-       // ----------------------------------------------------------------------------
-       install_dir = getFolder("Chrome", _packg_l );
-       logComment( "Installing to: " + install_dir );
-
-       // ----------------------------------------------------------------------------
-       // Directory where the 'content' is stored
-       // ----------------------------------------------------------------------------
-       content_dir = getFolder( install_dir, "content" );
-       if( err != 0 ) { return warn("getFolder:content_dir: " + err);}
-       
-       // ----------------------------------------------------------------------------
-       // Directory where the skins are stored
-       // ----------------------------------------------------------------------------
-       skin_dir = getFolder( install_dir, "skin" );
-       if( err != 0 ) { return warn("getFolder:skin: " + err);}
-
-       // ----------------------------------------------------------------------------
-       // Directory where the local data is stored
-       // ----------------------------------------------------------------------------
-       locale_dir = getFolder( install_dir, "locale" );
-       if( err != 0 ) { return warn("getFolder:locale: " + err);}
-
-       // ----------------------------------------------------------------------------
-       // Sets the install directory for Evergreen
-       // ----------------------------------------------------------------------------
-       err = setPackageFolder(install_dir);
-       if( err != 0 ) { return warn("setPackageFolder: " + err);}
-       
-       // ----------------------------------------------------------------------------
-       // Searches the .xpi file for the directory name stored in _packg_l and
-       // copies that directory from the .xpi into Mozilla's chrome directory.
-       // In this case, we are copying over the entire evergreen folder
-       // ----------------------------------------------------------------------------
-       err = addDirectory( _packg_l )
-       if( err != 0 ) { return warn("addDirectory: " + err);}
-       
-
-       // ----------------------------------------------------------------------------
-       // Register the content directory
-       // The final argument is where Mozilla should expect to find the contents.rdf 
-       // file *after* installation for the CONTENT portion of the package
-       // ----------------------------------------------------------------------------
-       err = registerChrome( Install.CONTENT, content_dir );
-       if( err != 0 ) { return warn("registerChrome:content  " + err );}
-       
-       // ----------------------------------------------------------------------------
-       // Register the skin directory
-       // ----------------------------------------------------------------------------
-       err = registerChrome( Install.SKIN, skin_dir );
-       if( err != 0 ) { return warn("registerChrome:skin " + err );}
-
-       // ----------------------------------------------------------------------------
-       // Register the locale directory 
-       // ----------------------------------------------------------------------------
-       //err = registerChrome( Install.LOCALE, locale_dir );
-       //if( err != 0 ) { return warn("registerChrome:locale " + err );}
-
-       err = registerChrome( Install.LOCALE, getFolder(locale_dir, "en-US") );
-       if( err != 0 ) { return warn("registerChrome:locale " + err );}
-
-       // ----------------------------------------------------------------------------
-       // Do it.
-       // ----------------------------------------------------------------------------
-       performInstall();
-       
-}
-
-function warn( message ) {
-       alert( message );
-       logComment( message );
-       return;
-}
-
diff --git a/examples/math_xul_client/math/content/conf/client_config.xml b/examples/math_xul_client/math/content/conf/client_config.xml
deleted file mode 100644 (file)
index 0dc75a9..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-<?xml version="1.0" ?>
-
-<oils_config>
-
-       <!-- General system settings -->
-
-       <system>
-               <hostname>myhostname</hostname>
-
-               <!-- log_level
-                       Levels run between 0 and 3.  O is no logging.  3 is full debug output -->
-               <log_level>0</log_level>
-
-               <!--  stdout_log
-                       When set to 0, no stdout logging is done, when set to 1, all logging
-                       goes to both stdout as well as their destined log file, if set to
-                       2, the messages only go to stdout.  -->
-               <stdout_log>0</stdout_log>
-       </system>
-
-
-       <!-- Log files -->
-
-       <logs>
-               <debug>debug.log</debug>
-               <transport>transport.log</transport>
-               <error>error.log</error>
-       </logs>
-
-       <!-- Remote services -->
-
-       <remote_service>
-               <math>router@localhost/math</math>
-               <mathdb>router@localhost/mathdb</mathdb>
-               <storage>router@localhost/storage</storage>
-       </remote_service>
-       
-       <!-- Transport -->
-
-       <transport>
-               <transport_impl>jabber_connection</transport_impl>
-
-               <!-- connect_timeout doubles as both the low level transport timeout
-                       as well as the app connection timeout -->
-               <connect_timeout>15</connect_timeout>
-               <username>math_user</username>
-               <password>math_user_password</password>
-               <primary>localhost</primary>
-               <port>5222</port>
-               <ssl>0</ssl>
-       </transport>
-
-</oils_config>
diff --git a/examples/math_xul_client/math/content/contents.rdf b/examples/math_xul_client/math/content/contents.rdf
deleted file mode 100644 (file)
index 7a8fb13..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0"?>
-
-<RDF:RDF xmlns:RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
-       xmlns:chrome="http://www.mozilla.org/rdf/chrome#">
-
-       <RDF:Seq about="urn:mozilla:package:root">
-               <RDF:li resource="urn:mozilla:package:math"/>
-       </RDF:Seq>
-
-       <RDF:Description about="urn:mozilla:package:math"
-               chrome:displayName="Math"
-               chrome:author="PINES"
-               chrome:name="math"
-               chrome:extension="true"/>
-
-</RDF:RDF>
-
diff --git a/examples/math_xul_client/math/content/math.xul b/examples/math_xul_client/math/content/math.xul
deleted file mode 100644 (file)
index d6a1371..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
-<?xml version="1.0"?>
-<!-- Test Application: Math -->
-
-<!-- Stylesheets -->
-<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
-<?xml-stylesheet href="chrome://math/skin/math.css" type="text/css"?>
-
-<!-- Localization -->
-<!DOCTYPE window SYSTEM "chrome://math/locale/math.dtd">
-
-<window id="math_win" title="&math.title;" orient="vertical" style="overflow: auto"
-       xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
-
-       <!-- Overlays for this XUL file -->
-       <?xul-overlay href="chrome://math/content/math_overlay.xul"?>
-
-       <!-- OpenSRF -->
-       <script>var myPackageDir = "math";</script>
-       <script src="OpenSRF/JSON_v1.js" />
-       <script src="OpenSRF/md5.js" />
-       <script src="OpenSRF/opensrf_utils.js" />
-       <script src="OpenSRF/opensrf_config.js" />
-       <script src="OpenSRF/opensrf_dom_element.js" />
-       <script src="OpenSRF/opensrf_domain_object.js" />
-       <script src="OpenSRF/opensrf_transport.js" />
-       <script src="OpenSRF/opensrf_jabber_transport.js" />
-       <script src="OpenSRF/opensrf_msg_stack.js" />
-       <script src="OpenSRF/opensrf_app_session.js" />
-
-       <!-- The logic for this app -->
-       <script src="math_app.js" />
-
-       <!-- Layout to be filled in by overlays and javascript -->
-       <vbox id="main_vbox" class="test_class">
-       </vbox>
-
-</window>
-
diff --git a/examples/math_xul_client/math/content/math_app.js b/examples/math_xul_client/math/content/math_app.js
deleted file mode 100644 (file)
index 2b98694..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-// connect and stup
-
-var ses;
-
-function execute( opp ) {
-
-       var a = document.getElementById("num1");
-       var b = document.getElementById("num2");
-       do_stuff( opp, a.value, b.value );
-
-}
-
-function do_stuff( opp, a, b ) {
-
-
-
-       try {
-
-               if( ses == null || ! AppSession.transport_handle.connected() ) {
-
-                       /* deprecated */
-                       ses = new AppSession( "user_name", "12345", "math" );
-                       if( ! ses.connect() ) { alert( "Connect timed out!" ); }
-               }
-
-               var meth = new oilsMethod(opp, [ a, b ] );
-
-               var req = new AppRequest( ses, meth );
-               req.make_request();
-               var resp = req.recv( 5000 );
-               if( ! resp ) {
-                       alert( "NO response from server!!!" );
-                       quit(); return;
-               }
-       
-               var scalar = resp.getContent();
-               var value = scalar.getValue();
-
-               var lab = document.getElementById( "answer" );
-               lab.value = "Answer: " + value;
-               req.finish();
-
-       } catch( E ) { alert( E.message ); }    
-
-}
-
-
-function quit() { ses.disconnect(); window.close(); }
-
-
diff --git a/examples/math_xul_client/math/content/math_overlay.xul b/examples/math_xul_client/math/content/math_overlay.xul
deleted file mode 100644 (file)
index 1a4b69c..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0"?>
-<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
-<?xml-stylesheet href="chrome://math/skin/math.css" type="text/css"?>
-<!DOCTYPE overlay SYSTEM "chrome://math/locale/math.dtd">
-<overlay id="math_overlay" 
-       xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
-
-<vbox id="main_vbox" flex="1">
-       <label value="&math.title;" />
-       <textbox id="num1" />
-       <textbox id="num2" />
-       <grid flex="1" class="test_class">
-               <columns>
-                       <column />
-                       <column />
-               </columns>
-               <rows>
-                       <row>
-                               <button label="&math.add;" oncommand="execute('add');"/>
-                               <button label="&math.sub;" oncommand="execute('sub');"/>
-                       </row>
-                       <row>
-                               <button label="&math.mul;" oncommand="execute('mult');"/>
-                               <button label="&math.div;" oncommand="execute('div');"/>
-                       </row>
-               </rows>
-       </grid>
-       <label id="answer" value="" />
-       <button label="&math.quit;" oncommand="quit();"/>
-</vbox>
-
-</overlay>
diff --git a/examples/math_xul_client/math/locale/en-US/contents.rdf b/examples/math_xul_client/math/locale/en-US/contents.rdf
deleted file mode 100644 (file)
index 01b2e7f..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-<?xml version="1.0"?>
-<RDF:RDF xmlns:RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
-          xmlns:chrome="http://www.mozilla.org/rdf/chrome#">
-       <RDF:Seq about="urn:mozilla:locale:root">
-               <RDF:li resource="urn:mozilla:locale:en-US"/>
-       </RDF:Seq>
-
-       <RDF:Description about="urn:mozilla:locale:en-US"
-               chrome:displayName="Math"
-               chrome:author="PINES"
-               chrome:name="en-US">
-               <chrome:packages>
-                       <RDF:Seq about="urn:mozilla:locale:en-US:packages">
-                               <RDF:li resource="urn:mozilla:locale:en-US:math"/>      
-                       </RDF:Seq>
-               </chrome:packages>
-       </RDF:Description>
-</RDF:RDF>
-
diff --git a/examples/math_xul_client/math/locale/en-US/math.dtd b/examples/math_xul_client/math/locale/en-US/math.dtd
deleted file mode 100644 (file)
index 16917f6..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-<!ENTITY math.title "Math App">
-<!ENTITY math.add "Add">
-<!ENTITY math.sub "Subtract">
-<!ENTITY math.mul "Multiply">
-<!ENTITY math.div "Divide">
-<!ENTITY math.quit "Quit">
-
diff --git a/examples/math_xul_client/math/skin/contents.rdf b/examples/math_xul_client/math/skin/contents.rdf
deleted file mode 100644 (file)
index b27f9ca..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0"?>
-
-<RDF:RDF xmlns:RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
-       xmlns:chrome="http://www.mozilla.org/rdf/chrome#">
-
-       <RDF:Seq about="urn:mozilla:skin:root">
-               <RDF:li resource="urn:mozilla:skin:math/1.0"/>
-       </RDF:Seq>
-
-       <RDF:Description about="urn:mozilla:skin:math/1.0"
-               chrome:displayName="Math"
-               chrome:author="PINES"
-               chrome:name="math/1.0">
-
-               <chrome:packages>
-                       <RDF:Seq about="urn:mozilla:skin:math/1.0:packages">
-                               <RDF:li resource="urn:mozilla:skin:math/1.0:math"/>     
-                       </RDF:Seq>
-               </chrome:packages>
-       </RDF:Description>
-
-</RDF:RDF>
-
diff --git a/examples/math_xul_client/math/skin/math.css b/examples/math_xul_client/math/skin/math.css
deleted file mode 100644 (file)
index 106bd74..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-@namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"); 
-@namespace html url("http://www.w3.org/TR/REC-html40"); 
-
-.test_class { border: solid thin blue; }