You can subscribe to this list here.
2009 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(29) |
Aug
(75) |
Sep
(32) |
Oct
(147) |
Nov
(31) |
Dec
(49) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2010 |
Jan
(46) |
Feb
(35) |
Mar
(148) |
Apr
(33) |
May
(53) |
Jun
(46) |
Jul
(60) |
Aug
(44) |
Sep
(135) |
Oct
(23) |
Nov
(68) |
Dec
(42) |
2011 |
Jan
(94) |
Feb
(55) |
Mar
(114) |
Apr
(78) |
May
(64) |
Jun
(10) |
Jul
(31) |
Aug
(2) |
Sep
(25) |
Oct
(13) |
Nov
(8) |
Dec
(24) |
2012 |
Jan
(5) |
Feb
(33) |
Mar
(31) |
Apr
(19) |
May
(24) |
Jun
(23) |
Jul
(14) |
Aug
(15) |
Sep
(12) |
Oct
(3) |
Nov
(4) |
Dec
(19) |
2013 |
Jan
(8) |
Feb
(20) |
Mar
(4) |
Apr
(2) |
May
(1) |
Jun
(2) |
Jul
|
Aug
(1) |
Sep
(2) |
Oct
(1) |
Nov
(4) |
Dec
|
2014 |
Jan
|
Feb
|
Mar
(6) |
Apr
(1) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2015 |
Jan
(7) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(6) |
2016 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(3) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2019 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(2) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Wolfgang K. <wol...@xm...> - 2009-10-11 17:37:40
|
The patch you sent makes sense to me. Its pretty much the same as it is implemented in UIButton. To catch more than one event type with the same target it is possible to provide the ORed values of the corresponding UIControlEventValues. The iPhone SDK reference says: For example, you could request a certain action message be sent to a certain target when a finger touches down in a control or is dragged into it (|UIControlEventTouchDown <http://developer.apple.com/iphone/library/documentation/UIKit/Reference/UIControl_Class/Reference/Reference.html#//apple_ref/c/econst/UIControlEventTouchDown>| | |UIControlEventTouchDragEnter <http://developer.apple.com/iphone/library/documentation/UIKit/Reference/UIControl_Class/Reference/Reference.html#//apple_ref/c/econst/UIControlEventTouchDragEnter>|). -- Wolfgang Panayotis Katsaloulis wrote: > > On 11 Οκτ 2009, at 10:05 π.μ., Wolfgang Korn wrote: > >> The only features a UIButton supports right now is creation, setting its >> title and to register an event handler. Especially all the color stuff >> you mentioned is currently not supported. What you saw in the Java >> version of UIButton (these methods based on java.awt.Color) are only >> used inside our Java emulator to create a UIAlertView with properly >> colored buttons. This Java implementation should be fixed as soon as we >> support color operations based in UIColor. And thanks for mentioning the >> UIButtonTest. Since this uses the java.awt.Color based methods it cannot >> be cross-compiled. I think we should remove that from the repository to >> avoid confusion. >> >> Coming to the String question. I lately noticed that the >> java_lang_String implementation is based on NSMutableString. This should >> be fixed since in Java strings are immutable. That's one thing I have on >> my list - but not with highest priority. >> > > > > So, for example I found that the UIControlEventValueChanged is not > understood in the simulator, while it is perfectly understood in the > native application. > In order to implement things like that in the emulator, is something > like this patch appropriate? > it still has some issues but I just want to understand the main idea. > > In order to catch more than one of these events, should I double the > request like here, or I can do something like > ( UIControlEventTouchUpInside | UIControlEventValueChanged ) > > > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------------ > Come build with us! The BlackBerry(R) Developer Conference in SF, CA > is the only developer event you need to attend this year. Jumpstart your > developing skills, take BlackBerry mobile applications to market and stay > ahead of the curve. Join us from November 9 - 12, 2009. Register now! > http://p.sf.net/sfu/devconference > ------------------------------------------------------------------------ > > _______________________________________________ > xmlvm-users mailing list > xml...@li... > https://lists.sourceforge.net/lists/listinfo/xmlvm-users > |
From: Wolfgang K. <wol...@xm...> - 2009-10-11 13:55:51
|
It seems that the pop2 instruction is used to clean up the stack here. Your code computes minimum and maximum of two values but simply ignores the computed value. To remove this computation result pop2 seems to be used. Until we implement the missing instruction you can simply assign the results from the calls to Math.min and Math.max to variables. In my case this removed the pop2 from the class file. One last thing: Could you please upload a patch file for your additions to Math.m/h to our review site (http://xmlvm-reviews.appspot.com/) or create a patch and send that instead of sending the whole files? This makes it easier to merge in case if concurrent modifications. -- Wolfgang Joseph Rukshan Fonseka wrote: > Hi, yes I did. I fixed the pow function name as suggested by Bjorn. I > have managed to compile it, but fails during linking. Attached is my > maths file and android source code. > > The compile error I get is: > > w.o obj/org_xmlvm_iphone_UITouch.o obj/org_xmlvm_iphone_UIView.o > obj/org_xmlvm_iphone_UIWindow.o obj/org_xmlvm_iphone_gl_BufferUtils.o > obj/org_xmlvm_iphone_gl_CAEAGLLayer.o > obj/org_xmlvm_iphone_gl_EAGLContext.o > obj/org_xmlvm_iphone_gl_EAGLDrawable.o obj/org_xmlvm_iphone_gl_GL.o > obj/org_xmlvm_iphone_gl_GLView.o obj/xmlvm.o > Undefined symbols: > "_ERROR", referenced from: > -[com_home_imageviewer_ImageViewer > onCreate___android_os_Bundle:] in com_home_imageviewer_ImageViewer.o > -[com_home_imageviewer_ImageViewer > onCreate___android_os_Bundle:] in com_home_imageviewer_ImageViewer.o > ld: symbol(s) not found > collect2: ld returned 1 exit status > make: *** [build/test.app/test] Error 1 > > > > ------------------------------------------------------------------------ > > > ------------------------------------------------------------------------ > > > ------------------------------------------------------------------------ > > > > On 11/10/2009, at 6:09 PM, Wolfgang Korn wrote: > >> Did you run the ant script to rebuild the library jars after >> implementing these Math methods? If yes - please send me a patch file >> with your implementation so that it is a little bit easier for me to >> add things to my workspace. Then I will have a look at what's going >> wrong and come back to as soon as possible. >> >> -- Wolfgang >> >> >> Joseph Rukshan Fonseka wrote: >>> Ok I added these to java_lang_Math.m >>> + (float) pow___float: (float) x : (float) y >>> { >>> return pow(x, y); >>> } >>> >>> + (double) pow___double: (double) x : (double) y >>> { >>> return pow(x, y); >>> } >>> + (float) max___float_float :(float) x :(float) y >>> { >>> return x < y ? y : x; >>> } >>> >>> + (double) max___double_double :(double) x :(double) y >>> { >>> return x < y ? y : x; >>> } >>> >>> + (int) max___int_int :(int) x :(int) y >>> { >>> return x < y ? y : x; >>> } >>> >>> + (float) min___float_float :(float) x :(float) y >>> { >>> return x > y ? y : x; >>> } >>> >>> + (double) min___double_double :(double) x :(double) y >>> { >>> return x > y ? y : x; >>> } >>> >>> + (int) min___int_int :(int) x :(int) y >>> { >>> return x > y ? y : x; >>> } >>> >>> and corresponding prototypes to the header file. >>> >>> However this android code: >>> public class ImageViewer extends Activity { >>> /** Called when the activity is first created. */ >>> @SuppressWarnings("deprecation") >>> @Override >>> public void onCreate(Bundle savedInstanceState) { >>> super.onCreate(savedInstanceState); >>> >>> AbsoluteLayout layout = new AbsoluteLayout(this); >>> layout.setLayoutParams(new >>> LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT)); >>> ImageView viewer = new ImageView(this); >>> viewer.setImageResource(R.drawable.cat); >>> layout.addView(viewer, new >>> AbsoluteLayout.LayoutParams(AbsoluteLayout.LayoutParams.WRAP_CONTENT, >>> AbsoluteLayout.LayoutParams.WRAP_CONTENT, 0, 100)); >>> TextView text = new TextView(this); >>> layout.addView(text, new >>> AbsoluteLayout.LayoutParams(AbsoluteLayout.LayoutParams.WRAP_CONTENT, >>> AbsoluteLayout.LayoutParams.WRAP_CONTENT, 0, 0)); >>> setContentView(layout); >>> >>> Math.pow(1.5,2*5); >>> Math.min(1.2, 3.0); >>> Math.max(3.4, 4.5); >>> } >>> } >>> >>> However cross compiling to iphone give me this error message: >>> com_home_imageviewer_ImageViewer.m:131: warning: ‘java_lang_Math’ >>> may not respond to ‘+pow___double_double::’ >>> com_home_imageviewer_ImageViewer.m:131: warning: (Messages without a >>> matching method signature >>> com_home_imageviewer_ImageViewer.m:131: warning: will be assumed to >>> return ‘id’ and accept >>> com_home_imageviewer_ImageViewer.m:131: warning: ‘...’ as arguments.) >>> com_home_imageviewer_ImageViewer.m:131: error: incompatible types in >>> assignment >>> com_home_imageviewer_ImageViewer.m:133: warning: implicit >>> declaration of function ‘ERROR’ >>> >>> >>> I am pretty confident it is due to the Math functions I am calling >>> at the end of my activity. Any idea what I am doing wrong? >>> >>> >>> On 09/10/2009, at 2:48 AM, Joseph Rukshan Fonseka wrote: >>> >>>> Ok I tried to convert an android application to iphone and noticed >>>> quite a few of the Maths functions don't compile such as >>>> >>>> Math.max() >>>> Math.min() >>>> Math.pow() >>>> >>>> I am guessing they aren't supported yet? I would like to extend the >>>> Maths library to have these functions. Which file should I be looking >>>> at to add these? >>>> >>>> Regards, >>>> Rukshan Fonseka. >>>> >>>> ------------------------------------------------------------------------------ >>>> Come build with us! The BlackBerry(R) Developer Conference in SF, CA >>>> is the only developer event you need to attend this year. Jumpstart >>>> your >>>> developing skills, take BlackBerry mobile applications to market >>>> and stay >>>> ahead of the curve. Join us from November 9 - 12, 2009. Register now! >>>> http://p.sf.net/sfu/devconference >>>> _______________________________________________ >>>> xmlvm-users mailing list >>>> xml...@li... >>>> <mailto:xml...@li...> >>>> https://lists.sourceforge.net/lists/listinfo/xmlvm-users >>> >>> ------------------------------------------------------------------------ >>> >>> ------------------------------------------------------------------------------ >>> Come build with us! The BlackBerry(R) Developer Conference in SF, CA >>> is the only developer event you need to attend this year. Jumpstart your >>> developing skills, take BlackBerry mobile applications to market and stay >>> ahead of the curve. Join us from November 9 - 12, 2009. Register now! >>> http://p.sf.net/sfu/devconference >>> ------------------------------------------------------------------------ >>> >>> _______________________________________________ >>> xmlvm-users mailing list >>> xml...@li... >>> https://lists.sourceforge.net/lists/listinfo/xmlvm-users >>> >> >> >> ------------------------------------------------------------------------------ >> Come build with us! The BlackBerry(R) Developer Conference in SF, CA >> is the only developer event you need to attend this year. Jumpstart your >> developing skills, take BlackBerry mobile applications to market and >> stay >> ahead of the curve. Join us from November 9 - 12, 2009. Register now! >> http://p.sf.net/sfu/devconference_______________________________________________ >> xmlvm-users mailing list >> xml...@li... >> https://lists.sourceforge.net/lists/listinfo/xmlvm-users > > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------------ > Come build with us! The BlackBerry(R) Developer Conference in SF, CA > is the only developer event you need to attend this year. Jumpstart your > developing skills, take BlackBerry mobile applications to market and stay > ahead of the curve. Join us from November 9 - 12, 2009. Register now! > http://p.sf.net/sfu/devconference > ------------------------------------------------------------------------ > > _______________________________________________ > xmlvm-users mailing list > xml...@li... > https://lists.sourceforge.net/lists/listinfo/xmlvm-users > |
From: Wolfgang K. <wol...@xm...> - 2009-10-11 13:43:37
|
I tried cross-compiling your application. It seems that the class file contains pop2 operations which isn't supported yet. -- Wolfgang Joseph Rukshan Fonseka wrote: > Hi, yes I did. I fixed the pow function name as suggested by Bjorn. I > have managed to compile it, but fails during linking. Attached is my > maths file and android source code. > > The compile error I get is: > > w.o obj/org_xmlvm_iphone_UITouch.o obj/org_xmlvm_iphone_UIView.o > obj/org_xmlvm_iphone_UIWindow.o obj/org_xmlvm_iphone_gl_BufferUtils.o > obj/org_xmlvm_iphone_gl_CAEAGLLayer.o > obj/org_xmlvm_iphone_gl_EAGLContext.o > obj/org_xmlvm_iphone_gl_EAGLDrawable.o obj/org_xmlvm_iphone_gl_GL.o > obj/org_xmlvm_iphone_gl_GLView.o obj/xmlvm.o > Undefined symbols: > "_ERROR", referenced from: > -[com_home_imageviewer_ImageViewer > onCreate___android_os_Bundle:] in com_home_imageviewer_ImageViewer.o > -[com_home_imageviewer_ImageViewer > onCreate___android_os_Bundle:] in com_home_imageviewer_ImageViewer.o > ld: symbol(s) not found > collect2: ld returned 1 exit status > make: *** [build/test.app/test] Error 1 > > > > ------------------------------------------------------------------------ > > > ------------------------------------------------------------------------ > > > ------------------------------------------------------------------------ > > > > On 11/10/2009, at 6:09 PM, Wolfgang Korn wrote: > >> Did you run the ant script to rebuild the library jars after >> implementing these Math methods? If yes - please send me a patch file >> with your implementation so that it is a little bit easier for me to >> add things to my workspace. Then I will have a look at what's going >> wrong and come back to as soon as possible. >> >> -- Wolfgang >> >> >> Joseph Rukshan Fonseka wrote: >>> Ok I added these to java_lang_Math.m >>> + (float) pow___float: (float) x : (float) y >>> { >>> return pow(x, y); >>> } >>> >>> + (double) pow___double: (double) x : (double) y >>> { >>> return pow(x, y); >>> } >>> + (float) max___float_float :(float) x :(float) y >>> { >>> return x < y ? y : x; >>> } >>> >>> + (double) max___double_double :(double) x :(double) y >>> { >>> return x < y ? y : x; >>> } >>> >>> + (int) max___int_int :(int) x :(int) y >>> { >>> return x < y ? y : x; >>> } >>> >>> + (float) min___float_float :(float) x :(float) y >>> { >>> return x > y ? y : x; >>> } >>> >>> + (double) min___double_double :(double) x :(double) y >>> { >>> return x > y ? y : x; >>> } >>> >>> + (int) min___int_int :(int) x :(int) y >>> { >>> return x > y ? y : x; >>> } >>> >>> and corresponding prototypes to the header file. >>> >>> However this android code: >>> public class ImageViewer extends Activity { >>> /** Called when the activity is first created. */ >>> @SuppressWarnings("deprecation") >>> @Override >>> public void onCreate(Bundle savedInstanceState) { >>> super.onCreate(savedInstanceState); >>> >>> AbsoluteLayout layout = new AbsoluteLayout(this); >>> layout.setLayoutParams(new >>> LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT)); >>> ImageView viewer = new ImageView(this); >>> viewer.setImageResource(R.drawable.cat); >>> layout.addView(viewer, new >>> AbsoluteLayout.LayoutParams(AbsoluteLayout.LayoutParams.WRAP_CONTENT, >>> AbsoluteLayout.LayoutParams.WRAP_CONTENT, 0, 100)); >>> TextView text = new TextView(this); >>> layout.addView(text, new >>> AbsoluteLayout.LayoutParams(AbsoluteLayout.LayoutParams.WRAP_CONTENT, >>> AbsoluteLayout.LayoutParams.WRAP_CONTENT, 0, 0)); >>> setContentView(layout); >>> >>> Math.pow(1.5,2*5); >>> Math.min(1.2, 3.0); >>> Math.max(3.4, 4.5); >>> } >>> } >>> >>> However cross compiling to iphone give me this error message: >>> com_home_imageviewer_ImageViewer.m:131: warning: ‘java_lang_Math’ >>> may not respond to ‘+pow___double_double::’ >>> com_home_imageviewer_ImageViewer.m:131: warning: (Messages without a >>> matching method signature >>> com_home_imageviewer_ImageViewer.m:131: warning: will be assumed to >>> return ‘id’ and accept >>> com_home_imageviewer_ImageViewer.m:131: warning: ‘...’ as arguments.) >>> com_home_imageviewer_ImageViewer.m:131: error: incompatible types in >>> assignment >>> com_home_imageviewer_ImageViewer.m:133: warning: implicit >>> declaration of function ‘ERROR’ >>> >>> >>> I am pretty confident it is due to the Math functions I am calling >>> at the end of my activity. Any idea what I am doing wrong? >>> >>> >>> On 09/10/2009, at 2:48 AM, Joseph Rukshan Fonseka wrote: >>> >>>> Ok I tried to convert an android application to iphone and noticed >>>> quite a few of the Maths functions don't compile such as >>>> >>>> Math.max() >>>> Math.min() >>>> Math.pow() >>>> >>>> I am guessing they aren't supported yet? I would like to extend the >>>> Maths library to have these functions. Which file should I be looking >>>> at to add these? >>>> >>>> Regards, >>>> Rukshan Fonseka. >>>> >>>> ------------------------------------------------------------------------------ >>>> Come build with us! The BlackBerry(R) Developer Conference in SF, CA >>>> is the only developer event you need to attend this year. Jumpstart >>>> your >>>> developing skills, take BlackBerry mobile applications to market >>>> and stay >>>> ahead of the curve. Join us from November 9 - 12, 2009. Register now! >>>> http://p.sf.net/sfu/devconference >>>> _______________________________________________ >>>> xmlvm-users mailing list >>>> xml...@li... >>>> <mailto:xml...@li...> >>>> https://lists.sourceforge.net/lists/listinfo/xmlvm-users >>> >>> ------------------------------------------------------------------------ >>> >>> ------------------------------------------------------------------------------ >>> Come build with us! The BlackBerry(R) Developer Conference in SF, CA >>> is the only developer event you need to attend this year. Jumpstart your >>> developing skills, take BlackBerry mobile applications to market and stay >>> ahead of the curve. Join us from November 9 - 12, 2009. Register now! >>> http://p.sf.net/sfu/devconference >>> ------------------------------------------------------------------------ >>> >>> _______________________________________________ >>> xmlvm-users mailing list >>> xml...@li... >>> https://lists.sourceforge.net/lists/listinfo/xmlvm-users >>> >> >> >> ------------------------------------------------------------------------------ >> Come build with us! The BlackBerry(R) Developer Conference in SF, CA >> is the only developer event you need to attend this year. Jumpstart your >> developing skills, take BlackBerry mobile applications to market and >> stay >> ahead of the curve. Join us from November 9 - 12, 2009. Register now! >> http://p.sf.net/sfu/devconference_______________________________________________ >> xmlvm-users mailing list >> xml...@li... >> https://lists.sourceforge.net/lists/listinfo/xmlvm-users > > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------------ > Come build with us! The BlackBerry(R) Developer Conference in SF, CA > is the only developer event you need to attend this year. Jumpstart your > developing skills, take BlackBerry mobile applications to market and stay > ahead of the curve. Join us from November 9 - 12, 2009. Register now! > http://p.sf.net/sfu/devconference > ------------------------------------------------------------------------ > > _______________________________________________ > xmlvm-users mailing list > xml...@li... > https://lists.sourceforge.net/lists/listinfo/xmlvm-users > |
From: Björn C. <bj...@ca...> - 2009-10-11 13:23:11
|
This problem is probably caused by missing support for a Java byte code. Look in the generated code for the _ERROR and you will see the byte code that is missing. /Björn Joseph Rukshan Fonseka skrev: > Hi, yes I did. I fixed the pow function name as suggested by Bjorn. I > have managed to compile it, but fails during linking. Attached is my > maths file and android source code. > > The compile error I get is: > > w.o obj/org_xmlvm_iphone_UITouch.o obj/org_xmlvm_iphone_UIView.o > obj/org_xmlvm_iphone_UIWindow.o obj/org_xmlvm_iphone_gl_BufferUtils.o > obj/org_xmlvm_iphone_gl_CAEAGLLayer.o > obj/org_xmlvm_iphone_gl_EAGLContext.o > obj/org_xmlvm_iphone_gl_EAGLDrawable.o obj/org_xmlvm_iphone_gl_GL.o > obj/org_xmlvm_iphone_gl_GLView.o obj/xmlvm.o > Undefined symbols: > "_ERROR", referenced from: > -[com_home_imageviewer_ImageViewer > onCreate___android_os_Bundle:] in com_home_imageviewer_ImageViewer.o > -[com_home_imageviewer_ImageViewer > onCreate___android_os_Bundle:] in com_home_imageviewer_ImageViewer.o > ld: symbol(s) not found > collect2: ld returned 1 exit status > make: *** [build/test.app/test] Error 1 > > > > ------------------------------------------------------------------------ > > > ------------------------------------------------------------------------ > > > ------------------------------------------------------------------------ > > > > On 11/10/2009, at 6:09 PM, Wolfgang Korn wrote: > >> Did you run the ant script to rebuild the library jars after >> implementing these Math methods? If yes - please send me a patch file >> with your implementation so that it is a little bit easier for me to >> add things to my workspace. Then I will have a look at what's going >> wrong and come back to as soon as possible. >> >> -- Wolfgang >> >> >> Joseph Rukshan Fonseka wrote: >>> Ok I added these to java_lang_Math.m >>> + (float) pow___float: (float) x : (float) y >>> { >>> return pow(x, y); >>> } >>> >>> + (double) pow___double: (double) x : (double) y >>> { >>> return pow(x, y); >>> } >>> + (float) max___float_float :(float) x :(float) y >>> { >>> return x < y ? y : x; >>> } >>> >>> + (double) max___double_double :(double) x :(double) y >>> { >>> return x < y ? y : x; >>> } >>> >>> + (int) max___int_int :(int) x :(int) y >>> { >>> return x < y ? y : x; >>> } >>> >>> + (float) min___float_float :(float) x :(float) y >>> { >>> return x > y ? y : x; >>> } >>> >>> + (double) min___double_double :(double) x :(double) y >>> { >>> return x > y ? y : x; >>> } >>> >>> + (int) min___int_int :(int) x :(int) y >>> { >>> return x > y ? y : x; >>> } >>> >>> and corresponding prototypes to the header file. >>> >>> However this android code: >>> public class ImageViewer extends Activity { >>> /** Called when the activity is first created. */ >>> @SuppressWarnings("deprecation") >>> @Override >>> public void onCreate(Bundle savedInstanceState) { >>> super.onCreate(savedInstanceState); >>> >>> AbsoluteLayout layout = new AbsoluteLayout(this); >>> layout.setLayoutParams(new >>> LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT)); >>> ImageView viewer = new ImageView(this); >>> viewer.setImageResource(R.drawable.cat); >>> layout.addView(viewer, new >>> AbsoluteLayout.LayoutParams(AbsoluteLayout.LayoutParams.WRAP_CONTENT, >>> AbsoluteLayout.LayoutParams.WRAP_CONTENT, 0, 100)); >>> TextView text = new TextView(this); >>> layout.addView(text, new >>> AbsoluteLayout.LayoutParams(AbsoluteLayout.LayoutParams.WRAP_CONTENT, >>> AbsoluteLayout.LayoutParams.WRAP_CONTENT, 0, 0)); >>> setContentView(layout); >>> >>> Math.pow(1.5,2*5); >>> Math.min(1.2, 3.0); >>> Math.max(3.4, 4.5); >>> } >>> } >>> >>> However cross compiling to iphone give me this error message: >>> com_home_imageviewer_ImageViewer.m:131: warning: ‘java_lang_Math’ >>> may not respond to ‘+pow___double_double::’ >>> com_home_imageviewer_ImageViewer.m:131: warning: (Messages without a >>> matching method signature >>> com_home_imageviewer_ImageViewer.m:131: warning: will be assumed to >>> return ‘id’ and accept >>> com_home_imageviewer_ImageViewer.m:131: warning: ‘...’ as arguments.) >>> com_home_imageviewer_ImageViewer.m:131: error: incompatible types in >>> assignment >>> com_home_imageviewer_ImageViewer.m:133: warning: implicit >>> declaration of function ‘ERROR’ >>> >>> >>> I am pretty confident it is due to the Math functions I am calling >>> at the end of my activity. Any idea what I am doing wrong? >>> >>> >>> On 09/10/2009, at 2:48 AM, Joseph Rukshan Fonseka wrote: >>> >>>> Ok I tried to convert an android application to iphone and noticed >>>> quite a few of the Maths functions don't compile such as >>>> >>>> Math.max() >>>> Math.min() >>>> Math.pow() >>>> >>>> I am guessing they aren't supported yet? I would like to extend the >>>> Maths library to have these functions. Which file should I be looking >>>> at to add these? >>>> >>>> Regards, >>>> Rukshan Fonseka. >>>> >>>> ------------------------------------------------------------------------------ >>>> Come build with us! The BlackBerry(R) Developer Conference in SF, CA >>>> is the only developer event you need to attend this year. Jumpstart >>>> your >>>> developing skills, take BlackBerry mobile applications to market >>>> and stay >>>> ahead of the curve. Join us from November 9 - 12, 2009. Register now! >>>> http://p.sf.net/sfu/devconference >>>> _______________________________________________ >>>> xmlvm-users mailing list >>>> xml...@li... >>>> <mailto:xml...@li...> >>>> https://lists.sourceforge.net/lists/listinfo/xmlvm-users >>> >>> ------------------------------------------------------------------------ >>> >>> ------------------------------------------------------------------------------ >>> Come build with us! The BlackBerry(R) Developer Conference in SF, CA >>> is the only developer event you need to attend this year. Jumpstart your >>> developing skills, take BlackBerry mobile applications to market and stay >>> ahead of the curve. Join us from November 9 - 12, 2009. Register now! >>> http://p.sf.net/sfu/devconference >>> ------------------------------------------------------------------------ >>> >>> _______________________________________________ >>> xmlvm-users mailing list >>> xml...@li... >>> https://lists.sourceforge.net/lists/listinfo/xmlvm-users >>> >> >> >> ------------------------------------------------------------------------------ >> Come build with us! The BlackBerry(R) Developer Conference in SF, CA >> is the only developer event you need to attend this year. Jumpstart your >> developing skills, take BlackBerry mobile applications to market and >> stay >> ahead of the curve. Join us from November 9 - 12, 2009. Register now! >> http://p.sf.net/sfu/devconference_______________________________________________ >> xmlvm-users mailing list >> xml...@li... >> https://lists.sourceforge.net/lists/listinfo/xmlvm-users > > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------------ > Come build with us! The BlackBerry(R) Developer Conference in SF, CA > is the only developer event you need to attend this year. Jumpstart your > developing skills, take BlackBerry mobile applications to market and stay > ahead of the curve. Join us from November 9 - 12, 2009. Register now! > http://p.sf.net/sfu/devconference > ------------------------------------------------------------------------ > > _______________________________________________ > xmlvm-users mailing list > xml...@li... > https://lists.sourceforge.net/lists/listinfo/xmlvm-users > |
From: Joseph R. F. <ruk...@op...> - 2009-10-11 13:17:35
|
Hi, yes I did. I fixed the pow function name as suggested by Bjorn. I have managed to compile it, but fails during linking. Attached is my maths file and android source code. The compile error I get is: w.o obj/org_xmlvm_iphone_UITouch.o obj/org_xmlvm_iphone_UIView.o obj/ org_xmlvm_iphone_UIWindow.o obj/org_xmlvm_iphone_gl_BufferUtils.o obj/ org_xmlvm_iphone_gl_CAEAGLLayer.o obj/ org_xmlvm_iphone_gl_EAGLContext.o obj/ org_xmlvm_iphone_gl_EAGLDrawable.o obj/org_xmlvm_iphone_gl_GL.o obj/ org_xmlvm_iphone_gl_GLView.o obj/xmlvm.o Undefined symbols: "_ERROR", referenced from: -[com_home_imageviewer_ImageViewer onCreate___android_os_Bundle:] in com_home_imageviewer_ImageViewer.o -[com_home_imageviewer_ImageViewer onCreate___android_os_Bundle:] in com_home_imageviewer_ImageViewer.o ld: symbol(s) not found collect2: ld returned 1 exit status make: *** [build/test.app/test] Error 1 On 11/10/2009, at 6:09 PM, Wolfgang Korn wrote: > Did you run the ant script to rebuild the library jars after > implementing these Math methods? If yes - please send me a patch > file with your implementation so that it is a little bit easier for > me to add things to my workspace. Then I will have a look at what's > going wrong and come back to as soon as possible. > > -- Wolfgang > > > Joseph Rukshan Fonseka wrote: >> >> Ok I added these to java_lang_Math.m >> + (float) pow___float: (float) x : (float) y >> { >> return pow(x, y); >> } >> >> + (double) pow___double: (double) x : (double) y >> { >> return pow(x, y); >> } >> + (float) max___float_float :(float) x :(float) y >> { >> return x < y ? y : x; >> } >> >> + (double) max___double_double :(double) x :(double) y >> { >> return x < y ? y : x; >> } >> >> + (int) max___int_int :(int) x :(int) y >> { >> return x < y ? y : x; >> } >> >> + (float) min___float_float :(float) x :(float) y >> { >> return x > y ? y : x; >> } >> >> + (double) min___double_double :(double) x :(double) y >> { >> return x > y ? y : x; >> } >> >> + (int) min___int_int :(int) x :(int) y >> { >> return x > y ? y : x; >> } >> >> and corresponding prototypes to the header file. >> >> However this android code: >> public class ImageViewer extends Activity { >> /** Called when the activity is first created. */ >> @SuppressWarnings("deprecation") >> @Override >> public void onCreate(Bundle savedInstanceState) { >> super.onCreate(savedInstanceState); >> >> AbsoluteLayout layout = new AbsoluteLayout(this); >> layout.setLayoutParams(new LayoutParams >> (LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT)); >> ImageView viewer = new ImageView(this); >> viewer.setImageResource(R.drawable.cat); >> layout.addView(viewer, new AbsoluteLayout.LayoutParams >> (AbsoluteLayout.LayoutParams.WRAP_CONTENT, >> AbsoluteLayout.LayoutParams.WRAP_CONTENT, 0, 100)); >> TextView text = new TextView(this); >> layout.addView(text, new AbsoluteLayout.LayoutParams >> (AbsoluteLayout.LayoutParams.WRAP_CONTENT, >> AbsoluteLayout.LayoutParams.WRAP_CONTENT, 0, 0)); >> setContentView(layout); >> >> Math.pow(1.5,2*5); >> Math.min(1.2, 3.0); >> Math.max(3.4, 4.5); >> } >> } >> >> However cross compiling to iphone give me this error message: >> com_home_imageviewer_ImageViewer.m:131: warning: ‘java_lang_Math’ >> may not respond to ‘+pow___double_double::’ >> com_home_imageviewer_ImageViewer.m:131: warning: (Messages without >> a matching method signature >> com_home_imageviewer_ImageViewer.m:131: warning: will be assumed to >> return ‘id’ and accept >> com_home_imageviewer_ImageViewer.m:131: warning: ‘...’ as arguments.) >> com_home_imageviewer_ImageViewer.m:131: error: incompatible types >> in assignment >> com_home_imageviewer_ImageViewer.m:133: warning: implicit >> declaration of function ‘ERROR’ >> >> >> I am pretty confident it is due to the Math functions I am calling >> at the end of my activity. Any idea what I am doing wrong? >> >> >> On 09/10/2009, at 2:48 AM, Joseph Rukshan Fonseka wrote: >> >>> Ok I tried to convert an android application to iphone and noticed >>> quite a few of the Maths functions don't compile such as >>> >>> Math.max() >>> Math.min() >>> Math.pow() >>> >>> I am guessing they aren't supported yet? I would like to extend the >>> Maths library to have these functions. Which file should I be >>> looking >>> at to add these? >>> >>> Regards, >>> Rukshan Fonseka. >>> >>> ------------------------------------------------------------------------------ >>> Come build with us! The BlackBerry(R) Developer Conference in SF, CA >>> is the only developer event you need to attend this year. >>> Jumpstart your >>> developing skills, take BlackBerry mobile applications to market >>> and stay >>> ahead of the curve. Join us from November 9 - 12, 2009. Register >>> now! >>> http://p.sf.net/sfu/devconference >>> _______________________________________________ >>> xmlvm-users mailing list >>> xml...@li... >>> https://lists.sourceforge.net/lists/listinfo/xmlvm-users >> >> >> ------------------------------------------------------------------------------ >> Come build with us! The BlackBerry(R) Developer Conference in SF, CA >> is the only developer event you need to attend this year. Jumpstart >> your >> developing skills, take BlackBerry mobile applications to market >> and stay >> ahead of the curve. Join us from November 9 - 12, 2009. Register now! >> http://p.sf.net/sfu/devconference >> >> _______________________________________________ >> xmlvm-users mailing list >> xml...@li... >> https://lists.sourceforge.net/lists/listinfo/xmlvm-users >> > > > ------------------------------------------------------------------------------ > Come build with us! The BlackBerry(R) Developer Conference in SF, CA > is the only developer event you need to attend this year. Jumpstart > your > developing skills, take BlackBerry mobile applications to market and > stay > ahead of the curve. Join us from November 9 - 12, 2009. Register now! > http://p.sf.net/sfu/devconference_______________________________________________ > xmlvm-users mailing list > xml...@li... > https://lists.sourceforge.net/lists/listinfo/xmlvm-users |
From: Wolfgang K. <wol...@xm...> - 2009-10-11 12:41:15
|
That's right. And the same is true for pow___float. -- Wolfgang Björn Caroll wrote: > Your pow method is misspelled. It needs another double. > > /Björn > > Joseph Rukshan Fonseka skrev: > >> Ok I added these to java_lang_Math.m >> + (float) pow___float: (float) x : (float) y >> { >> return pow(x, y); >> } >> >> + (double) pow___double: (double) x : (double) y >> { >> return pow(x, y); >> } >> + (float) max___float_float :(float) x :(float) y >> { >> return x < y ? y : x; >> } >> >> + (double) max___double_double :(double) x :(double) y >> { >> return x < y ? y : x; >> } >> >> + (int) max___int_int :(int) x :(int) y >> { >> return x < y ? y : x; >> } >> >> + (float) min___float_float :(float) x :(float) y >> { >> return x > y ? y : x; >> } >> >> + (double) min___double_double :(double) x :(double) y >> { >> return x > y ? y : x; >> } >> >> + (int) min___int_int :(int) x :(int) y >> { >> return x > y ? y : x; >> } >> >> and corresponding prototypes to the header file. >> >> However this android code: >> public class ImageViewer extends Activity { >> /** Called when the activity is first created. */ >> @SuppressWarnings("deprecation") >> @Override >> public void onCreate(Bundle savedInstanceState) { >> super.onCreate(savedInstanceState); >> >> >> >> AbsoluteLayout layout = new AbsoluteLayout(this); >> layout.setLayoutParams(new >> LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT)); >> ImageView viewer = new ImageView(this); >> viewer.setImageResource(R.drawable.cat); >> layout.addView(viewer, new >> AbsoluteLayout.LayoutParams(AbsoluteLayout.LayoutParams.WRAP_CONTENT, >> AbsoluteLayout.LayoutParams.WRAP_CONTENT, 0, 100)); >> TextView text = new TextView(this); >> layout.addView(text, new >> AbsoluteLayout.LayoutParams(AbsoluteLayout.LayoutParams.WRAP_CONTENT, >> AbsoluteLayout.LayoutParams.WRAP_CONTENT, 0, 0)); >> setContentView(layout); >> >> >> Math.pow(1.5,2*5); >> Math.min(1.2, 3.0); >> Math.max(3.4, 4.5); >> } >> } >> >> However cross compiling to iphone give me this error message: >> com_home_imageviewer_ImageViewer.m:131: warning: ‘java_lang_Math’ may >> not respond to ‘+pow___double_double::’ >> com_home_imageviewer_ImageViewer.m:131: warning: (Messages without a >> matching method signature >> com_home_imageviewer_ImageViewer.m:131: warning: will be assumed to >> return ‘id’ and accept >> com_home_imageviewer_ImageViewer.m:131: warning: ‘...’ as arguments.) >> com_home_imageviewer_ImageViewer.m:131: error: incompatible types in >> assignment >> com_home_imageviewer_ImageViewer.m:133: warning: implicit declaration >> of function ‘ERROR’ >> >> >> I am pretty confident it is due to the Math functions I am calling at >> the end of my activity. Any idea what I am doing wrong? >> >> >> On 09/10/2009, at 2:48 AM, Joseph Rukshan Fonseka wrote: >> >> >>> Ok I tried to convert an android application to iphone and noticed >>> quite a few of the Maths functions don't compile such as >>> >>> Math.max() >>> Math.min() >>> Math.pow() >>> >>> I am guessing they aren't supported yet? I would like to extend the >>> Maths library to have these functions. Which file should I be looking >>> at to add these? >>> >>> Regards, >>> Rukshan Fonseka. >>> >>> ------------------------------------------------------------------------------ >>> Come build with us! The BlackBerry(R) Developer Conference in SF, CA >>> is the only developer event you need to attend this year. Jumpstart your >>> developing skills, take BlackBerry mobile applications to market and >>> stay >>> ahead of the curve. Join us from November 9 - 12, 2009. Register now! >>> http://p.sf.net/sfu/devconference >>> _______________________________________________ >>> xmlvm-users mailing list >>> xml...@li... >>> <mailto:xml...@li...> >>> https://lists.sourceforge.net/lists/listinfo/xmlvm-users >>> >> ------------------------------------------------------------------------ >> >> ------------------------------------------------------------------------------ >> Come build with us! The BlackBerry(R) Developer Conference in SF, CA >> is the only developer event you need to attend this year. Jumpstart your >> developing skills, take BlackBerry mobile applications to market and stay >> ahead of the curve. Join us from November 9 - 12, 2009. Register now! >> http://p.sf.net/sfu/devconference >> ------------------------------------------------------------------------ >> >> _______________________________________________ >> xmlvm-users mailing list >> xml...@li... >> https://lists.sourceforge.net/lists/listinfo/xmlvm-users >> >> > > > ------------------------------------------------------------------------------ > Come build with us! The BlackBerry(R) Developer Conference in SF, CA > is the only developer event you need to attend this year. Jumpstart your > developing skills, take BlackBerry mobile applications to market and stay > ahead of the curve. Join us from November 9 - 12, 2009. Register now! > http://p.sf.net/sfu/devconference > _______________________________________________ > xmlvm-users mailing list > xml...@li... > https://lists.sourceforge.net/lists/listinfo/xmlvm-users > |
From: Panayotis K. <pan...@pa...> - 2009-10-11 09:55:07
|
On 11 Οκτ 2009, at 10:05 π.μ., Wolfgang Korn wrote: > The only features a UIButton supports right now is creation, setting > its > title and to register an event handler. Especially all the color stuff > you mentioned is currently not supported. What you saw in the Java > version of UIButton (these methods based on java.awt.Color) are only > used inside our Java emulator to create a UIAlertView with properly > colored buttons. This Java implementation should be fixed as soon as > we > support color operations based in UIColor. And thanks for mentioning > the > UIButtonTest. Since this uses the java.awt.Color based methods it > cannot > be cross-compiled. I think we should remove that from the repository > to > avoid confusion. > > Coming to the String question. I lately noticed that the > java_lang_String implementation is based on NSMutableString. This > should > be fixed since in Java strings are immutable. That's one thing I > have on > my list - but not with highest priority. > So, for example I found that the UIControlEventValueChanged is not understood in the simulator, while it is perfectly understood in the native application. In order to implement things like that in the emulator, is something like this patch appropriate? it still has some issues but I just want to understand the main idea. In order to catch more than one of these events, should I double the request like here, or I can do something like ( UIControlEventTouchUpInside | UIControlEventValueChanged ) |
From: Björn C. <bj...@ca...> - 2009-10-11 09:01:55
|
Your pow method is misspelled. It needs another double. /Björn Joseph Rukshan Fonseka skrev: > Ok I added these to java_lang_Math.m > + (float) pow___float: (float) x : (float) y > { > return pow(x, y); > } > > + (double) pow___double: (double) x : (double) y > { > return pow(x, y); > } > + (float) max___float_float :(float) x :(float) y > { > return x < y ? y : x; > } > > + (double) max___double_double :(double) x :(double) y > { > return x < y ? y : x; > } > > + (int) max___int_int :(int) x :(int) y > { > return x < y ? y : x; > } > > + (float) min___float_float :(float) x :(float) y > { > return x > y ? y : x; > } > > + (double) min___double_double :(double) x :(double) y > { > return x > y ? y : x; > } > > + (int) min___int_int :(int) x :(int) y > { > return x > y ? y : x; > } > > and corresponding prototypes to the header file. > > However this android code: > public class ImageViewer extends Activity { > /** Called when the activity is first created. */ > @SuppressWarnings("deprecation") > @Override > public void onCreate(Bundle savedInstanceState) { > super.onCreate(savedInstanceState); > > > > AbsoluteLayout layout = new AbsoluteLayout(this); > layout.setLayoutParams(new > LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT)); > ImageView viewer = new ImageView(this); > viewer.setImageResource(R.drawable.cat); > layout.addView(viewer, new > AbsoluteLayout.LayoutParams(AbsoluteLayout.LayoutParams.WRAP_CONTENT, > AbsoluteLayout.LayoutParams.WRAP_CONTENT, 0, 100)); > TextView text = new TextView(this); > layout.addView(text, new > AbsoluteLayout.LayoutParams(AbsoluteLayout.LayoutParams.WRAP_CONTENT, > AbsoluteLayout.LayoutParams.WRAP_CONTENT, 0, 0)); > setContentView(layout); > > > Math.pow(1.5,2*5); > Math.min(1.2, 3.0); > Math.max(3.4, 4.5); > } > } > > However cross compiling to iphone give me this error message: > com_home_imageviewer_ImageViewer.m:131: warning: ‘java_lang_Math’ may > not respond to ‘+pow___double_double::’ > com_home_imageviewer_ImageViewer.m:131: warning: (Messages without a > matching method signature > com_home_imageviewer_ImageViewer.m:131: warning: will be assumed to > return ‘id’ and accept > com_home_imageviewer_ImageViewer.m:131: warning: ‘...’ as arguments.) > com_home_imageviewer_ImageViewer.m:131: error: incompatible types in > assignment > com_home_imageviewer_ImageViewer.m:133: warning: implicit declaration > of function ‘ERROR’ > > > I am pretty confident it is due to the Math functions I am calling at > the end of my activity. Any idea what I am doing wrong? > > > On 09/10/2009, at 2:48 AM, Joseph Rukshan Fonseka wrote: > >> Ok I tried to convert an android application to iphone and noticed >> quite a few of the Maths functions don't compile such as >> >> Math.max() >> Math.min() >> Math.pow() >> >> I am guessing they aren't supported yet? I would like to extend the >> Maths library to have these functions. Which file should I be looking >> at to add these? >> >> Regards, >> Rukshan Fonseka. >> >> ------------------------------------------------------------------------------ >> Come build with us! The BlackBerry(R) Developer Conference in SF, CA >> is the only developer event you need to attend this year. Jumpstart your >> developing skills, take BlackBerry mobile applications to market and >> stay >> ahead of the curve. Join us from November 9 - 12, 2009. Register now! >> http://p.sf.net/sfu/devconference >> _______________________________________________ >> xmlvm-users mailing list >> xml...@li... >> <mailto:xml...@li...> >> https://lists.sourceforge.net/lists/listinfo/xmlvm-users > > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------------ > Come build with us! The BlackBerry(R) Developer Conference in SF, CA > is the only developer event you need to attend this year. Jumpstart your > developing skills, take BlackBerry mobile applications to market and stay > ahead of the curve. Join us from November 9 - 12, 2009. Register now! > http://p.sf.net/sfu/devconference > ------------------------------------------------------------------------ > > _______________________________________________ > xmlvm-users mailing list > xml...@li... > https://lists.sourceforge.net/lists/listinfo/xmlvm-users > |
From: Wolfgang K. <wol...@xm...> - 2009-10-11 07:09:40
|
Did you run the ant script to rebuild the library jars after implementing these Math methods? If yes - please send me a patch file with your implementation so that it is a little bit easier for me to add things to my workspace. Then I will have a look at what's going wrong and come back to as soon as possible. -- Wolfgang Joseph Rukshan Fonseka wrote: > Ok I added these to java_lang_Math.m > + (float) pow___float: (float) x : (float) y > { > return pow(x, y); > } > > + (double) pow___double: (double) x : (double) y > { > return pow(x, y); > } > + (float) max___float_float :(float) x :(float) y > { > return x < y ? y : x; > } > > + (double) max___double_double :(double) x :(double) y > { > return x < y ? y : x; > } > > + (int) max___int_int :(int) x :(int) y > { > return x < y ? y : x; > } > > + (float) min___float_float :(float) x :(float) y > { > return x > y ? y : x; > } > > + (double) min___double_double :(double) x :(double) y > { > return x > y ? y : x; > } > > + (int) min___int_int :(int) x :(int) y > { > return x > y ? y : x; > } > > and corresponding prototypes to the header file. > > However this android code: > public class ImageViewer extends Activity { > /** Called when the activity is first created. */ > @SuppressWarnings("deprecation") > @Override > public void onCreate(Bundle savedInstanceState) { > super.onCreate(savedInstanceState); > > > > AbsoluteLayout layout = new AbsoluteLayout(this); > layout.setLayoutParams(new > LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT)); > ImageView viewer = new ImageView(this); > viewer.setImageResource(R.drawable.cat); > layout.addView(viewer, new > AbsoluteLayout.LayoutParams(AbsoluteLayout.LayoutParams.WRAP_CONTENT, > AbsoluteLayout.LayoutParams.WRAP_CONTENT, 0, 100)); > TextView text = new TextView(this); > layout.addView(text, new > AbsoluteLayout.LayoutParams(AbsoluteLayout.LayoutParams.WRAP_CONTENT, > AbsoluteLayout.LayoutParams.WRAP_CONTENT, 0, 0)); > setContentView(layout); > > > Math.pow(1.5,2*5); > Math.min(1.2, 3.0); > Math.max(3.4, 4.5); > } > } > > However cross compiling to iphone give me this error message: > com_home_imageviewer_ImageViewer.m:131: warning: ‘java_lang_Math’ may > not respond to ‘+pow___double_double::’ > com_home_imageviewer_ImageViewer.m:131: warning: (Messages without a > matching method signature > com_home_imageviewer_ImageViewer.m:131: warning: will be assumed to > return ‘id’ and accept > com_home_imageviewer_ImageViewer.m:131: warning: ‘...’ as arguments.) > com_home_imageviewer_ImageViewer.m:131: error: incompatible types in > assignment > com_home_imageviewer_ImageViewer.m:133: warning: implicit declaration > of function ‘ERROR’ > > > I am pretty confident it is due to the Math functions I am calling at > the end of my activity. Any idea what I am doing wrong? > > > On 09/10/2009, at 2:48 AM, Joseph Rukshan Fonseka wrote: > >> Ok I tried to convert an android application to iphone and noticed >> quite a few of the Maths functions don't compile such as >> >> Math.max() >> Math.min() >> Math.pow() >> >> I am guessing they aren't supported yet? I would like to extend the >> Maths library to have these functions. Which file should I be looking >> at to add these? >> >> Regards, >> Rukshan Fonseka. >> >> ------------------------------------------------------------------------------ >> Come build with us! The BlackBerry(R) Developer Conference in SF, CA >> is the only developer event you need to attend this year. Jumpstart your >> developing skills, take BlackBerry mobile applications to market and >> stay >> ahead of the curve. Join us from November 9 - 12, 2009. Register now! >> http://p.sf.net/sfu/devconference >> _______________________________________________ >> xmlvm-users mailing list >> xml...@li... >> <mailto:xml...@li...> >> https://lists.sourceforge.net/lists/listinfo/xmlvm-users > > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------------ > Come build with us! The BlackBerry(R) Developer Conference in SF, CA > is the only developer event you need to attend this year. Jumpstart your > developing skills, take BlackBerry mobile applications to market and stay > ahead of the curve. Join us from November 9 - 12, 2009. Register now! > http://p.sf.net/sfu/devconference > ------------------------------------------------------------------------ > > _______________________________________________ > xmlvm-users mailing list > xml...@li... > https://lists.sourceforge.net/lists/listinfo/xmlvm-users > |
From: Wolfgang K. <wol...@xm...> - 2009-10-11 07:06:06
|
The only features a UIButton supports right now is creation, setting its title and to register an event handler. Especially all the color stuff you mentioned is currently not supported. What you saw in the Java version of UIButton (these methods based on java.awt.Color) are only used inside our Java emulator to create a UIAlertView with properly colored buttons. This Java implementation should be fixed as soon as we support color operations based in UIColor. And thanks for mentioning the UIButtonTest. Since this uses the java.awt.Color based methods it cannot be cross-compiled. I think we should remove that from the repository to avoid confusion. Coming to the String question. I lately noticed that the java_lang_String implementation is based on NSMutableString. This should be fixed since in Java strings are immutable. That's one thing I have on my list - but not with highest priority. -- Wolfgang Panayotis Katsaloulis wrote: > OK, now things start to get a bit dirty! > > The urge of this post was my effort to compile ibutton test (to do > some real work at last :P ) This demo does not compile, since > java.awt.Color is missing. > So, although methods in java.lang.Math seem to be straight forward how > to implement them ;-) , this gets a bit more complicated (since it > doesn't exist at all). > And it gets even more complicated if I had a look at "mixed" files, > such as UITextView and UIButton. > > I have to admit it, I am totally lost :) > > UITextField is pretty clear what it does, no surprises there. What is > on the java-side is also on the obj-c side. > > UIButton though is completely out of sync. Except the static method > which created the UIButton (which makes sense) and setTitle forState, > all other methods are missing! > Are missing methods actually methods *not* really allowed to be > executed in the obj-c environment (e.g. for emulation purposes?). Is > for example "setPressedBackgroundColor(Color)" one of them? > At the end of the day, is org_xmlvm_iphone_UIButton actually a UIButton? > > Let's go back to the original problem: > UILabel.setBackgroundColor wants a Color argument. Is this on purpose? > Isn't there a confusion whether UIColor or Color should be used? Can > this be solved? > What exactly should I do to implement the missing link? > > And a question out of curiosity: is java.lang.String a NSMutableString > after all? > > Too many questions, I know, but I's all new (and exciting) for me… and > I want to help :) > ------------------------------------------------------------------------------ > Come build with us! The BlackBerry(R) Developer Conference in SF, CA > is the only developer event you need to attend this year. Jumpstart your > developing skills, take BlackBerry mobile applications to market and stay > ahead of the curve. Join us from November 9 - 12, 2009. Register now! > http://p.sf.net/sfu/devconference > _______________________________________________ > xmlvm-users mailing list > xml...@li... > https://lists.sourceforge.net/lists/listinfo/xmlvm-users > |
From: Wolfgang K. <wol...@xm...> - 2009-10-11 06:55:01
|
We have the NoAutoReleasePool annotation which inhibits the creation of an autorelease pool. We use that to prevent anonymous inner classes from being released right after creation when a method returns. This problem occurred for event handler which should clearly live longer than just for the method where they were created. So this is not really an optimization. We also do not have something like an explicit release since there is nothing like this in Java or the Android API. To avoid memory leaks due to circular dependencies you have to first break the cycle by manually by deleting on of the references forming the cycle so that it is no longer cyclic. After that you can "forget" the reference to the cycle and the objects will be cleaned up. -- Wolfgang Panayotis Katsaloulis wrote: > On 10 Οκτ 2009, at 11:54 μ.μ., Wolfgang Korn wrote: > > >> We make use of reference counting and the autorelease pool mechanism >> offered by Cocoa. Since reference counting is not as powerful as a >> full-fledged garbage collector there is a limitation with this >> approach: >> Using reference counting does not clean up unreferenced circular data >> structures, what a garbage collector of course would do. So you have >> to >> be a little bit careful to avoid this - otherwise the cross compiled >> application would have a memory leak. >> > > I've seen here > http://www.cokeandcode.com/XMLVM-OpenGL-Support-Patch-Commited > which talks about annotations. > > I looked at the source code and I saw this, in file > XMLVMNoAutoReleasePool.java > @Retention(RetentionPolicy.CLASS) > so, is there any way to "optimize" GC with annotations? > > And, one more thing, is there a way to force send an object to > oblivion, e.g. when we have cycle dependencies like the one mentioned > above (and I just want to free some memory) ? > > > > ------------------------------------------------------------------------------ > Come build with us! The BlackBerry(R) Developer Conference in SF, CA > is the only developer event you need to attend this year. Jumpstart your > developing skills, take BlackBerry mobile applications to market and stay > ahead of the curve. Join us from November 9 - 12, 2009. Register now! > http://p.sf.net/sfu/devconference > _______________________________________________ > xmlvm-users mailing list > xml...@li... > https://lists.sourceforge.net/lists/listinfo/xmlvm-users > |
From: Joseph R. F. <ruk...@op...> - 2009-10-11 04:20:03
|
Ok I added these to java_lang_Math.m + (float) pow___float: (float) x : (float) y { return pow(x, y); } + (double) pow___double: (double) x : (double) y { return pow(x, y); } + (float) max___float_float :(float) x :(float) y { return x < y ? y : x; } + (double) max___double_double :(double) x :(double) y { return x < y ? y : x; } + (int) max___int_int :(int) x :(int) y { return x < y ? y : x; } + (float) min___float_float :(float) x :(float) y { return x > y ? y : x; } + (double) min___double_double :(double) x :(double) y { return x > y ? y : x; } + (int) min___int_int :(int) x :(int) y { return x > y ? y : x; } and corresponding prototypes to the header file. However this android code: public class ImageViewer extends Activity { /** Called when the activity is first created. */ @SuppressWarnings("deprecation") @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); AbsoluteLayout layout = new AbsoluteLayout(this); layout.setLayoutParams(new LayoutParams (LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT)); ImageView viewer = new ImageView(this); viewer.setImageResource(R.drawable.cat); layout.addView(viewer, new AbsoluteLayout.LayoutParams (AbsoluteLayout.LayoutParams.WRAP_CONTENT, AbsoluteLayout.LayoutParams.WRAP_CONTENT, 0, 100)); TextView text = new TextView(this); layout.addView(text, new AbsoluteLayout.LayoutParams (AbsoluteLayout.LayoutParams.WRAP_CONTENT, AbsoluteLayout.LayoutParams.WRAP_CONTENT, 0, 0)); setContentView(layout); Math.pow(1.5,2*5); Math.min(1.2, 3.0); Math.max(3.4, 4.5); } } However cross compiling to iphone give me this error message: com_home_imageviewer_ImageViewer.m:131: warning: ‘java_lang_Math’ may not respond to ‘+pow___double_double::’ com_home_imageviewer_ImageViewer.m:131: warning: (Messages without a matching method signature com_home_imageviewer_ImageViewer.m:131: warning: will be assumed to return ‘id’ and accept com_home_imageviewer_ImageViewer.m:131: warning: ‘...’ as arguments.) com_home_imageviewer_ImageViewer.m:131: error: incompatible types in assignment com_home_imageviewer_ImageViewer.m:133: warning: implicit declaration of function ‘ERROR’ I am pretty confident it is due to the Math functions I am calling at the end of my activity. Any idea what I am doing wrong? On 09/10/2009, at 2:48 AM, Joseph Rukshan Fonseka wrote: > Ok I tried to convert an android application to iphone and noticed > quite a few of the Maths functions don't compile such as > > Math.max() > Math.min() > Math.pow() > > I am guessing they aren't supported yet? I would like to extend the > Maths library to have these functions. Which file should I be looking > at to add these? > > Regards, > Rukshan Fonseka. > > ------------------------------------------------------------------------------ > Come build with us! The BlackBerry(R) Developer Conference in SF, CA > is the only developer event you need to attend this year. Jumpstart > your > developing skills, take BlackBerry mobile applications to market and > stay > ahead of the curve. Join us from November 9 - 12, 2009. Register now! > http://p.sf.net/sfu/devconference > _______________________________________________ > xmlvm-users mailing list > xml...@li... > https://lists.sourceforge.net/lists/listinfo/xmlvm-users |
From: Panayotis K. <pan...@pa...> - 2009-10-11 01:11:38
|
OK, now things start to get a bit dirty! The urge of this post was my effort to compile ibutton test (to do some real work at last :P ) This demo does not compile, since java.awt.Color is missing. So, although methods in java.lang.Math seem to be straight forward how to implement them ;-) , this gets a bit more complicated (since it doesn't exist at all). And it gets even more complicated if I had a look at "mixed" files, such as UITextView and UIButton. I have to admit it, I am totally lost :) UITextField is pretty clear what it does, no surprises there. What is on the java-side is also on the obj-c side. UIButton though is completely out of sync. Except the static method which created the UIButton (which makes sense) and setTitle forState, all other methods are missing! Are missing methods actually methods *not* really allowed to be executed in the obj-c environment (e.g. for emulation purposes?). Is for example "setPressedBackgroundColor(Color)" one of them? At the end of the day, is org_xmlvm_iphone_UIButton actually a UIButton? Let's go back to the original problem: UILabel.setBackgroundColor wants a Color argument. Is this on purpose? Isn't there a confusion whether UIColor or Color should be used? Can this be solved? What exactly should I do to implement the missing link? And a question out of curiosity: is java.lang.String a NSMutableString after all? Too many questions, I know, but I's all new (and exciting) for me… and I want to help :) |
From: Sascha H. <sa...@xm...> - 2009-10-10 23:41:04
|
Hi John, when I refactored our XMLVM structure a while ago, the CLR backend was not added. The reason for this was mainly because we never had usable support for JVM to CLR translation. As far as I know, the only stylesheets we have so far are jvm2clr.xsl and clr-api.xsl, which together have not even 150 lines in them. So instead of putting this incomplete and very unusable components back in we decided to not add it for now. Right now we are focusing on the Objective-C and JavaScript backends, as the smartphone market is the most important one right now. So I don't expect us (the core team) to work on this anytime soon. However, if you feel that you can do good progress on this, we are looking forward to help you on your way. We have put a lot of effort in the other direction (CLR to JVM), as this is actually a bit more difficult, but that's another story. Some things will be easier to map from JVM to CLR. E.g. all the add instructions like iadd, fadd, dadd etc can be mapped to a single add instruction in the CLR world. Again, if you wish to proceed on this we would be happy about your contribution and could also help you if you get stuck. // Sascha On Sun, Oct 11, 2009 at 1:02 AM, John <jo...@tr...> wrote: > Some slight progress - have managed to cobble together a new > ClrOutputProcess so that .net bytecode is being converted again. > Actually managed to get a "hello world" exe out of it, which was nice. > > However a slightly more complicated test trips things up, as the > following jvm instructions don't get translated: > jvm:new > jvm:dup > jvm:astore > > jvm:new is interesting as it seems that it's just the first of a > handful of instructions responsible for creating a new object. The clr > on the other hand appears to be one big newobj instruction, so I'm not > sure how to write a suitable transform to do that. > > I'm also not sure what the clr equivilents of jvm:dup and jvm:astore are. > > Also doesn't seem to cope with anything other than a single .class > file as input at the moment. Any hints on how to deal with these > problems appreciated. > > > On Sat, Oct 10, 2009 at 8:49 PM, John <jo...@tr...> wrote: > > Hello, > > > > I'm interested in using xmlvm so I can develop jvm and .net vm > > versions of the same app with as much shared code as possible. I've > > been trying to get a basic hello-world example working but always get > > the error "Could not create OutputProcess for target 'EXE'." > > > > A bit of poking around in the source seems to suggest that the EXE and > > CLR pipelines have vanished - in particular > > OutputProcessFactory.createOutputProcess doesn't recognise these > > targets any more. Will these be restored any time soon? What's the > > current status of the clr backend? > > > > Assuming this is just a glitch, can anyone tell me how far along the > > clr backend is? Looking through the jvm2clr directory things look a > > little... sparse. I wouldn't mind helping out but right now I wouldn't > > have a clue where to start. > > > > Regards, > > > > > ------------------------------------------------------------------------------ > Come build with us! The BlackBerry(R) Developer Conference in SF, CA > is the only developer event you need to attend this year. Jumpstart your > developing skills, take BlackBerry mobile applications to market and stay > ahead of the curve. Join us from November 9 - 12, 2009. Register now! > http://p.sf.net/sfu/devconference > _______________________________________________ > xmlvm-users mailing list > xml...@li... > https://lists.sourceforge.net/lists/listinfo/xmlvm-users > |
From: John <jo...@tr...> - 2009-10-10 23:03:10
|
Some slight progress - have managed to cobble together a new ClrOutputProcess so that .net bytecode is being converted again. Actually managed to get a "hello world" exe out of it, which was nice. However a slightly more complicated test trips things up, as the following jvm instructions don't get translated: jvm:new jvm:dup jvm:astore jvm:new is interesting as it seems that it's just the first of a handful of instructions responsible for creating a new object. The clr on the other hand appears to be one big newobj instruction, so I'm not sure how to write a suitable transform to do that. I'm also not sure what the clr equivilents of jvm:dup and jvm:astore are. Also doesn't seem to cope with anything other than a single .class file as input at the moment. Any hints on how to deal with these problems appreciated. On Sat, Oct 10, 2009 at 8:49 PM, John <jo...@tr...> wrote: > Hello, > > I'm interested in using xmlvm so I can develop jvm and .net vm > versions of the same app with as much shared code as possible. I've > been trying to get a basic hello-world example working but always get > the error "Could not create OutputProcess for target 'EXE'." > > A bit of poking around in the source seems to suggest that the EXE and > CLR pipelines have vanished - in particular > OutputProcessFactory.createOutputProcess doesn't recognise these > targets any more. Will these be restored any time soon? What's the > current status of the clr backend? > > Assuming this is just a glitch, can anyone tell me how far along the > clr backend is? Looking through the jvm2clr directory things look a > little... sparse. I wouldn't mind helping out but right now I wouldn't > have a clue where to start. > > Regards, > |
From: Sascha H. <sa...@xm...> - 2009-10-10 21:39:48
|
Hi XMLVM users, I am happy to announce the availability of an HTML version of our manual. You can find it here: http://xmlvm.org/manual/ It is also linked to from our documentation page. We continue to work on improving the documentation site further in the next time. Thanks // Sascha |
From: Panayotis K. <pan...@pa...> - 2009-10-10 21:32:04
|
On 10 Οκτ 2009, at 11:54 μ.μ., Wolfgang Korn wrote: > We make use of reference counting and the autorelease pool mechanism > offered by Cocoa. Since reference counting is not as powerful as a > full-fledged garbage collector there is a limitation with this > approach: > Using reference counting does not clean up unreferenced circular data > structures, what a garbage collector of course would do. So you have > to > be a little bit careful to avoid this - otherwise the cross compiled > application would have a memory leak. I've seen here http://www.cokeandcode.com/XMLVM-OpenGL-Support-Patch-Commited which talks about annotations. I looked at the source code and I saw this, in file XMLVMNoAutoReleasePool.java @Retention(RetentionPolicy.CLASS) so, is there any way to "optimize" GC with annotations? And, one more thing, is there a way to force send an object to oblivion, e.g. when we have cycle dependencies like the one mentioned above (and I just want to free some memory) ? |
From: Wolfgang K. <wol...@xm...> - 2009-10-10 20:55:02
|
We make use of reference counting and the autorelease pool mechanism offered by Cocoa. Since reference counting is not as powerful as a full-fledged garbage collector there is a limitation with this approach: Using reference counting does not clean up unreferenced circular data structures, what a garbage collector of course would do. So you have to be a little bit careful to avoid this - otherwise the cross compiled application would have a memory leak. -- Wolfgang Panayotis Katsaloulis wrote: > I have this question: > > iPhone does not have GC, while Java is the only way to go. > Given that iPhone is a small device, with limited memory (and they > have disabled GC for a good reason), how is memory managed with XMLVM? > > ------------------------------------------------------------------------------ > Come build with us! The BlackBerry(R) Developer Conference in SF, CA > is the only developer event you need to attend this year. Jumpstart your > developing skills, take BlackBerry mobile applications to market and stay > ahead of the curve. Join us from November 9 - 12, 2009. Register now! > http://p.sf.net/sfu/devconference > _______________________________________________ > xmlvm-users mailing list > xml...@li... > https://lists.sourceforge.net/lists/listinfo/xmlvm-users > |
From: Panayotis K. <pan...@pa...> - 2009-10-10 20:39:00
|
I have this question: iPhone does not have GC, while Java is the only way to go. Given that iPhone is a small device, with limited memory (and they have disabled GC for a good reason), how is memory managed with XMLVM? |
From: John <jo...@tr...> - 2009-10-10 19:50:15
|
Hello, I'm interested in using xmlvm so I can develop jvm and .net vm versions of the same app with as much shared code as possible. I've been trying to get a basic hello-world example working but always get the error "Could not create OutputProcess for target 'EXE'." A bit of poking around in the source seems to suggest that the EXE and CLR pipelines have vanished - in particular OutputProcessFactory.createOutputProcess doesn't recognise these targets any more. Will these be restored any time soon? What's the current status of the clr backend? Assuming this is just a glitch, can anyone tell me how far along the clr backend is? Looking through the jvm2clr directory things look a little... sparse. I wouldn't mind helping out but right now I wouldn't have a clue where to start. Regards, |
From: Wolfgang K. <wol...@xm...> - 2009-10-10 19:32:45
|
We really appreciate these patches since they make working with XMLVM a lot easier! As soon as they are merged to the SVN HEAD we will announce it here on the list. As Panayotis already mentioned this will probably take a little bit more than a week. -- Wolfgang Panayotis Katsaloulis wrote: > Just to inform the community, in case someone is working on the same > thing, not to do duplicated work. > > I am working on ways to make xmlvm friendlier to other not-so- > technically-advanced people. > Basically to people who just want to try this project and create some > stuff, as easy as possible. > Only being easy this project will succeed ;-) > > I have already created some patches which I have sent to the developer > team for validation, they told me in a week or so (since now they > can't) they will be patched on the main tree (hopefully). > The basic target was to create specific templates for projects and > lower the things someone needs to know before developing with xmlvm. > > Now it will be possible to > > a) Create a hello-world template, from inside the program, as a first > step of the development cycle > > b) Easier linking with xmlvm.jar file only, during the development > cycle, no need to search for libraries or include these PNG files > which usually break java execution > > c) Automatically create an XCode project, based on your compiled > project, so it would be easy to target cases, as distributing and > installing on the iphone > > These are the main points (with smaller other improvements of course). > > If anyone wants to have a look at it, I'll be glad to send it to have > a look and test these features (although they should work fine, after > my tests). > > > > ------------------------------------------------------------------------------ > Come build with us! The BlackBerry(R) Developer Conference in SF, CA > is the only developer event you need to attend this year. Jumpstart your > developing skills, take BlackBerry mobile applications to market and stay > ahead of the curve. Join us from November 9 - 12, 2009. Register now! > http://p.sf.net/sfu/devconference > _______________________________________________ > xmlvm-users mailing list > xml...@li... > https://lists.sourceforge.net/lists/listinfo/xmlvm-users > |
From: Panayotis K. <pan...@pa...> - 2009-10-10 19:27:40
|
Just to inform the community, in case someone is working on the same thing, not to do duplicated work. I am working on ways to make xmlvm friendlier to other not-so- technically-advanced people. Basically to people who just want to try this project and create some stuff, as easy as possible. Only being easy this project will succeed ;-) I have already created some patches which I have sent to the developer team for validation, they told me in a week or so (since now they can't) they will be patched on the main tree (hopefully). The basic target was to create specific templates for projects and lower the things someone needs to know before developing with xmlvm. Now it will be possible to a) Create a hello-world template, from inside the program, as a first step of the development cycle b) Easier linking with xmlvm.jar file only, during the development cycle, no need to search for libraries or include these PNG files which usually break java execution c) Automatically create an XCode project, based on your compiled project, so it would be easy to target cases, as distributing and installing on the iphone These are the main points (with smaller other improvements of course). If anyone wants to have a look at it, I'll be glad to send it to have a look and test these features (although they should work fine, after my tests). |
From: Wolfgang K. <wol...@xm...> - 2009-10-10 10:56:07
|
Of course you have to specify what should be cross compiled - that's what the --in parameter is used for. You can either specify a single file to be cross compiled (i.e. a .class file) or a folder. In the latter case all files in that folder (.class ., .exe and .xmlvm) will be cross compiled. For more details see page 10 of manual.pdf. -- Wolfgang Shraddha Damle wrote: > Hi, > > I want to use XMLVM for my application.For that,I installed JDK1.6.I > have 'XMLVM.jar' file.I have build the XMLVM successfully through ant > utility. > > Now,as per ur documentation XMLVM.pdf,in order to invoke XMLVM,command > given in documentation is > *'java -jar dist/xmlvm.jar'* > but It didn't work,else it asks for atleast one --in parameter.what > --in parameter value should I Provide? > > Can u plz help me out in this issue as early as possible? > > Regards, > Shraddha |
From: Wolfgang K. <wol...@xm...> - 2009-10-10 10:50:46
|
re...@xm... is actually a distribution list which currently includes all of the three core developers. -- Wolfgang Panayotis Katsaloulis wrote: > On 08 Οκτ 2009, at 6:35 μ.μ., Wolfgang Korn wrote: > > >> The process how to properly submit a patch is described on the XMLVM >> site at http://xmlvm.org/contribute/ . Basically we use a code >> review portal at http://xmlvm-reviews.appspot.com/ to accept and >> review patches. >> >> And indeed - I also prefer to have the patches submitted there >> instead of being posted to the list. After merging a patch to the >> XMLVM HEAD a notification on the list about it would be a good thing >> anyway. >> >> -- Wolfgang >> > > > Who is receiving re...@xm... ? > ------------------------------------------------------------------------------ > Come build with us! The BlackBerry(R) Developer Conference in SF, CA > is the only developer event you need to attend this year. Jumpstart your > developing skills, take BlackBerry mobile applications to market and stay > ahead of the curve. Join us from November 9 - 12, 2009. Register now! > http://p.sf.net/sfu/devconference > _______________________________________________ > xmlvm-users mailing list > xml...@li... > https://lists.sourceforge.net/lists/listinfo/xmlvm-users > |
From: Panayotis K. <pan...@pa...> - 2009-10-10 10:23:50
|
On 08 Οκτ 2009, at 6:35 μ.μ., Wolfgang Korn wrote: > The process how to properly submit a patch is described on the XMLVM > site at http://xmlvm.org/contribute/ . Basically we use a code > review portal at http://xmlvm-reviews.appspot.com/ to accept and > review patches. > > And indeed - I also prefer to have the patches submitted there > instead of being posted to the list. After merging a patch to the > XMLVM HEAD a notification on the list about it would be a good thing > anyway. > > -- Wolfgang Who is receiving re...@xm... ? |