Author: remi
Date: 2009-04-15 14:00:28 +0200 (Wed, 15 Apr 2009)
New Revision: 4517

Modified:
   
softwares_suite_v3/community/gadget/tuxdroid-gadget-feed/main_gadget/trunk/tuxdroid-gadget-feed/pom.xml
   
softwares_suite_v3/community/gadget/tuxdroid-gadget-feed/main_gadget/trunk/tuxdroid-gadget-feed/resources/gadget.xml
   
softwares_suite_v3/community/gadget/tuxdroid-gadget-feed/main_gadget/trunk/tuxdroid-gadget-feed/sources/net/karmaLab/tuxDroid/gadgets/FeedGadget.java
Log:
* adapted the gadget to perfectly run in the python framework.
* bumped to 1.2

Modified: 
softwares_suite_v3/community/gadget/tuxdroid-gadget-feed/main_gadget/trunk/tuxdroid-gadget-feed/pom.xml
===================================================================
--- 
softwares_suite_v3/community/gadget/tuxdroid-gadget-feed/main_gadget/trunk/tuxdroid-gadget-feed/pom.xml
     2009-04-15 11:45:25 UTC (rev 4516)
+++ 
softwares_suite_v3/community/gadget/tuxdroid-gadget-feed/main_gadget/trunk/tuxdroid-gadget-feed/pom.xml
     2009-04-15 12:00:28 UTC (rev 4517)
@@ -4,7 +4,7 @@
     <groupId>com.kysoh</groupId>
     <artifactId>tuxdroid-gadget-feed</artifactId>
     <packaging>jar</packaging>
-    <version>1.1</version>
+    <version>1.2</version>
     <name>Feed gadget for Tux Droid</name>
     <url>http://www.tuxisalive.com</url>
     
@@ -13,7 +13,7 @@
        <dependency>
            <groupId>com.kysoh</groupId>
            <artifactId>tuxdroid-gadget-java-kit</artifactId>
-           <version>0.0.1</version>
+           <version>0.0.2</version>
        </dependency>
        <dependency>
            <groupId>net.karmaLab</groupId>
@@ -75,10 +75,14 @@
                                <copy 
file="${project.build.directory}/${project.artifactId}-${project.version}.jar"
                                    todir="./libraries" />
                                <zip destfile="./${project.artifactId}.tgf">
-                                   <zipfileset dir="." includes="resources/*" 
/>
-                                   <zipfileset dir="." includes="libraries/*" 
/>
-                                   <zipfileset dir="." 
includes="executables/*" />
-                               </zip>
+                            <zipfileset dir="." includes="resources/*" />
+                            <zipfileset dir="." includes="libraries/*" >
+                                <exclude 
name="libraries/tuxdroid-gadget-java-kit*" />
+                                <exclude name="libraries/karmalab-commons*" />
+                                <exclude name="libraries/tuxdroid-java-api*" />
+                            </zipfileset>
+                            <zipfileset dir="." includes="executables/*" />
+                        </zip>
                            </tasks>
                        </configuration>
                        <goals>

Modified: 
softwares_suite_v3/community/gadget/tuxdroid-gadget-feed/main_gadget/trunk/tuxdroid-gadget-feed/resources/gadget.xml
===================================================================
--- 
softwares_suite_v3/community/gadget/tuxdroid-gadget-feed/main_gadget/trunk/tuxdroid-gadget-feed/resources/gadget.xml
        2009-04-15 11:45:25 UTC (rev 4516)
+++ 
softwares_suite_v3/community/gadget/tuxdroid-gadget-feed/main_gadget/trunk/tuxdroid-gadget-feed/resources/gadget.xml
        2009-04-15 12:00:28 UTC (rev 4517)
@@ -8,7 +8,7 @@
                <name>Feeds Gadget</name>
                <description>This gadget queries for RSS feed 
updates</description>
                <author>Yoran Brault</author>
-               <version>1.1</version>
+               <version>1.2</version>
                <iconFile>resources/gadget.png</iconFile>
                <executionMode>command</executionMode>
                <uuid>b1abb710-2abf-4daa-8748-25bc79e22967</uuid>
@@ -40,11 +40,11 @@
                        defaultValue="false" />
        </parameters>
        <commands>
+        <command
+                       name="run"
+                       description="Check the feed" />
                <command
                        name="check"
                        description="Check the feed" />
-               <command
-                       name="run"
-                       description="Check the feed" />
        </commands>
 </gadget>

Modified: 
softwares_suite_v3/community/gadget/tuxdroid-gadget-feed/main_gadget/trunk/tuxdroid-gadget-feed/sources/net/karmaLab/tuxDroid/gadgets/FeedGadget.java
===================================================================
--- 
softwares_suite_v3/community/gadget/tuxdroid-gadget-feed/main_gadget/trunk/tuxdroid-gadget-feed/sources/net/karmaLab/tuxDroid/gadgets/FeedGadget.java
       2009-04-15 11:45:25 UTC (rev 4516)
+++ 
softwares_suite_v3/community/gadget/tuxdroid-gadget-feed/main_gadget/trunk/tuxdroid-gadget-feed/sources/net/karmaLab/tuxDroid/gadgets/FeedGadget.java
       2009-04-15 12:00:28 UTC (rev 4517)
@@ -166,12 +166,22 @@
                }
                 // Catch a timeout / bad connection
                catch (java.net.UnknownHostException e) {
-                       throwMessage("Sorry, I could not connect to the rss 
server. Please check your internet connection or try again later.");
-                       return;
+            if (!this.isNotified()) {
+                throwMessage("Sorry, I could not connect to the rss server. 
Please check your internet connection or try again later.");
+                       }
+            else {
+                throwResult(false);
+            }
+            return;
                }
                 // Catch a malformed URL
                catch (java.io.IOException e) {
-                       throwMessage("Sorry, I couldn't find the feed url. 
Please check your rss configuration.");
+            if (!this.isNotified()) {
+                throwMessage("Sorry, I couldn't find the feed url. Please 
check your rss configuration.");
+            }
+            else {
+                throwResult(false);
+            }
                        return;
                }
 
@@ -213,12 +223,23 @@
                        }
                }
                if (notification) {
+            if (this.isNotified()) {
+                throwResult(true);
+            }
                        throwMessage(message);
                }
+        else {
+            if (this.isNotified()) {
+                throwResult(false);
+            }
+        }
 
                if (this.isNotified()) {
                        writeState(state, configuration().getTitle());
                }
        }
 
+    @Override
+    public void onGadgetStop() {
+    }
 }


------------------------------------------------------------------------------
This SF.net email is sponsored by:
High Quality Requirements in a Collaborative Environment.
Download a free trial of Rational Requirements Composer Now!
http://p.sf.net/sfu/www-ibm-com
_______________________________________________
Tux-droid-svn mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tux-droid-svn

Reply via email to