[libbluray-devel] Implement org.havi.ui.HStaticIcon

Ian Curtis git at videolan.org
Sat Apr 12 18:11:33 CEST 2014


libbluray | branch: master | Ian Curtis <i.curtis at gmail.com> | Sat Apr 12 19:06:32 2014 +0300| [a2e38c23781438b538ad3e34c5325a28b19777c5] | committer: hpi1

Implement org.havi.ui.HStaticIcon

> http://git.videolan.org/gitweb.cgi/libbluray.git/?a=commit;h=a2e38c23781438b538ad3e34c5325a28b19777c5
---

 src/libbluray/bdj/java/org/havi/ui/HStaticIcon.java |   13 +++++++++----
 1 file changed, 9 insertions(+), 4 deletions(-)

diff --git a/src/libbluray/bdj/java/org/havi/ui/HStaticIcon.java b/src/libbluray/bdj/java/org/havi/ui/HStaticIcon.java
index f661f44..3979230 100644
--- a/src/libbluray/bdj/java/org/havi/ui/HStaticIcon.java
+++ b/src/libbluray/bdj/java/org/havi/ui/HStaticIcon.java
@@ -24,31 +24,36 @@ import java.awt.Image;
 public class HStaticIcon extends HVisible implements HNoInputPreferred {
     public HStaticIcon()
     {
-        org.videolan.Logger.unimplemented(HStaticIcon.class.getName(), "");
+        super(getDefaultLook());
     }
 
     public HStaticIcon(Image imageNormal, int x, int y, int width, int height)
     {
-        org.videolan.Logger.unimplemented(HStaticIcon.class.getName(), "");
+        super(getDefaultLook(), x, y, width, height);
+        setGraphicContent(imageNormal, NORMAL_STATE);
     }
 
     public HStaticIcon(Image imageNormal)
     {
-        org.videolan.Logger.unimplemented(HStaticIcon.class.getName(), "");
+        super(getDefaultLook());
+        setGraphicContent(imageNormal, NORMAL_STATE);
     }
 
     public void setLook(HLook hlook) throws HInvalidLookException
     {
-        throw new Error("Not implemented");
+        if ((hlook != null) && !(hlook instanceof HGraphicLook)) throw new HInvalidLookException();
+        super.setLook(hlook);
     }
 
     public static void setDefaultLook(HGraphicLook hlook)
     {
+        //TODO double check this
         DefaultLook = hlook;
     }
 
     public static HGraphicLook getDefaultLook()
     {
+        //TODO and this
         if (DefaultLook == null)
             org.videolan.Logger.unimplemented("", "getDefaultLook");
         return DefaultLook;



More information about the libbluray-devel mailing list