SlideShare a Scribd company logo
1 of 22
Download to read offline
Hacking the Source - Part III
package com.codename1.demos.kitchen;
import com.codename1.impl.javase.JavaSEPort;
import com.codename1.ui.Display;
import java.awt.event.WindowAdapter;
import java.awt.event.WindowEvent;
import javax.swing.JFrame;
import javax.swing.SwingUtilities;
public class KitchenSinkStub implements Runnable {
private static JFrame frm;
private KitchenSink mainApp;
private static final int APP_WIDTH = 800;
private static final int APP_HEIGHT = 600;
public static void main(String[] args) {
JavaSEPort.setNativeTheme("/iOS7Theme.res");
JavaSEPort.blockMonitors();
JavaSEPort.setShowEDTViolationStacks(false);
JavaSEPort.setShowEDTWarnings(false);
JavaSEPort.setAppHomeDir(".KitchenSink");
JavaSEPort.setExposeFilesystem(true);
JavaSEPort.setTablet(true);
JavaSEPort.setUseNativeInput(true);
JavaSEPort.setDefaultPixelMilliRatio(new Double(10));
SwingUtilities.invokeLater(new KitchenSinkStub());
}
KitchenSinkStub (Desktop)
package com.codename1.demos.kitchen;
import com.codename1.impl.javase.JavaSEPort;
import com.codename1.ui.Display;
import java.awt.event.WindowAdapter;
import java.awt.event.WindowEvent;
import javax.swing.JFrame;
import javax.swing.SwingUtilities;
public class KitchenSinkStub implements Runnable {
private static JFrame frm;
private KitchenSink mainApp;
private static final int APP_WIDTH = 800;
private static final int APP_HEIGHT = 600;
public static void main(String[] args) {
JavaSEPort.setNativeTheme("/iOS7Theme.res");
JavaSEPort.blockMonitors();
JavaSEPort.setShowEDTViolationStacks(false);
JavaSEPort.setShowEDTWarnings(false);
JavaSEPort.setAppHomeDir(".KitchenSink");
JavaSEPort.setExposeFilesystem(true);
JavaSEPort.setTablet(true);
JavaSEPort.setUseNativeInput(true);
JavaSEPort.setDefaultPixelMilliRatio(new Double(10));
SwingUtilities.invokeLater(new KitchenSinkStub());
}
KitchenSinkStub (Desktop)
package com.codename1.demos.kitchen;
import com.codename1.impl.javase.JavaSEPort;
import com.codename1.ui.Display;
import java.awt.event.WindowAdapter;
import java.awt.event.WindowEvent;
import javax.swing.JFrame;
import javax.swing.SwingUtilities;
public class KitchenSinkStub implements Runnable {
private static JFrame frm;
private KitchenSink mainApp;
private static final int APP_WIDTH = 800;
private static final int APP_HEIGHT = 600;
public static void main(String[] args) {
JavaSEPort.setNativeTheme("/iOS7Theme.res");
JavaSEPort.blockMonitors();
JavaSEPort.setShowEDTViolationStacks(false);
JavaSEPort.setShowEDTWarnings(false);
JavaSEPort.setAppHomeDir(".KitchenSink");
JavaSEPort.setExposeFilesystem(true);
JavaSEPort.setTablet(true);
JavaSEPort.setUseNativeInput(true);
JavaSEPort.setDefaultPixelMilliRatio(new Double(10));
SwingUtilities.invokeLater(new KitchenSinkStub());
}
KitchenSinkStub (Desktop)
package com.codename1.demos.kitchen;
import com.codename1.impl.javase.JavaSEPort;
import com.codename1.ui.Display;
import java.awt.event.WindowAdapter;
import java.awt.event.WindowEvent;
import javax.swing.JFrame;
import javax.swing.SwingUtilities;
public class KitchenSinkStub implements Runnable {
private static JFrame frm;
private KitchenSink mainApp;
private static final int APP_WIDTH = 800;
private static final int APP_HEIGHT = 600;
public static void main(String[] args) {
JavaSEPort.setNativeTheme("/iOS7Theme.res");
JavaSEPort.blockMonitors();
JavaSEPort.setShowEDTViolationStacks(false);
JavaSEPort.setShowEDTWarnings(false);
JavaSEPort.setAppHomeDir(".KitchenSink");
JavaSEPort.setExposeFilesystem(true);
JavaSEPort.setTablet(true);
JavaSEPort.setUseNativeInput(true);
JavaSEPort.setDefaultPixelMilliRatio(new Double(10));
SwingUtilities.invokeLater(new KitchenSinkStub());
}
KitchenSinkStub (Desktop)
package com.codename1.demos.kitchen;
import com.codename1.impl.javase.JavaSEPort;
import com.codename1.ui.Display;
import java.awt.event.WindowAdapter;
import java.awt.event.WindowEvent;
import javax.swing.JFrame;
import javax.swing.SwingUtilities;
public class KitchenSinkStub implements Runnable {
private static JFrame frm;
private KitchenSink mainApp;
private static final int APP_WIDTH = 800;
private static final int APP_HEIGHT = 600;
public static void main(String[] args) {
JavaSEPort.setNativeTheme("/iOS7Theme.res");
JavaSEPort.blockMonitors();
JavaSEPort.setShowEDTViolationStacks(false);
JavaSEPort.setShowEDTWarnings(false);
JavaSEPort.setAppHomeDir(".KitchenSink");
JavaSEPort.setExposeFilesystem(true);
JavaSEPort.setTablet(true);
JavaSEPort.setUseNativeInput(true);
JavaSEPort.setDefaultPixelMilliRatio(new Double(10));
SwingUtilities.invokeLater(new KitchenSinkStub());
}
KitchenSinkStub (Desktop)
package com.codename1.demos.kitchen;
import com.codename1.impl.javase.JavaSEPort;
import com.codename1.ui.Display;
import java.awt.event.WindowAdapter;
import java.awt.event.WindowEvent;
import javax.swing.JFrame;
import javax.swing.SwingUtilities;
public class KitchenSinkStub implements Runnable {
private static JFrame frm;
private KitchenSink mainApp;
private static final int APP_WIDTH = 800;
private static final int APP_HEIGHT = 600;
public static void main(String[] args) {
JavaSEPort.setNativeTheme("/iOS7Theme.res");
JavaSEPort.blockMonitors();
JavaSEPort.setShowEDTViolationStacks(false);
JavaSEPort.setShowEDTWarnings(false);
JavaSEPort.setAppHomeDir(".KitchenSink");
JavaSEPort.setExposeFilesystem(true);
JavaSEPort.setTablet(true);
JavaSEPort.setUseNativeInput(true);
JavaSEPort.setDefaultPixelMilliRatio(new Double(10));
SwingUtilities.invokeLater(new KitchenSinkStub());
}
KitchenSinkStub (Desktop)
package com.codename1.demos.kitchen;
import com.codename1.impl.javase.JavaSEPort;
import com.codename1.ui.Display;
import java.awt.event.WindowAdapter;
import java.awt.event.WindowEvent;
import javax.swing.JFrame;
import javax.swing.SwingUtilities;
public class KitchenSinkStub implements Runnable {
private static JFrame frm;
private KitchenSink mainApp;
private static final int APP_WIDTH = 800;
private static final int APP_HEIGHT = 600;
public static void main(String[] args) {
JavaSEPort.setNativeTheme("/iOS7Theme.res");
JavaSEPort.blockMonitors();
JavaSEPort.setShowEDTViolationStacks(false);
JavaSEPort.setShowEDTWarnings(false);
JavaSEPort.setAppHomeDir(".KitchenSink");
JavaSEPort.setExposeFilesystem(true);
JavaSEPort.setTablet(true);
JavaSEPort.setUseNativeInput(true);
JavaSEPort.setDefaultPixelMilliRatio(new Double(10));
SwingUtilities.invokeLater(new KitchenSinkStub());
}
KitchenSinkStub (Desktop)
package com.codename1.demos.kitchen;
import com.codename1.impl.javase.JavaSEPort;
import com.codename1.ui.Display;
import java.awt.event.WindowAdapter;
import java.awt.event.WindowEvent;
import javax.swing.JFrame;
import javax.swing.SwingUtilities;
public class KitchenSinkStub implements Runnable {
private static JFrame frm;
private KitchenSink mainApp;
private static final int APP_WIDTH = 800;
private static final int APP_HEIGHT = 600;
public static void main(String[] args) {
JavaSEPort.setNativeTheme("/iOS7Theme.res");
JavaSEPort.blockMonitors();
JavaSEPort.setShowEDTViolationStacks(false);
JavaSEPort.setShowEDTWarnings(false);
JavaSEPort.setAppHomeDir(".KitchenSink");
JavaSEPort.setExposeFilesystem(true);
JavaSEPort.setTablet(true);
JavaSEPort.setUseNativeInput(true);
JavaSEPort.setDefaultPixelMilliRatio(new Double(10));
SwingUtilities.invokeLater(new KitchenSinkStub());
}
KitchenSinkStub (Desktop)
SwingUtilities.invokeLater(new KitchenSinkStub());
}
@Override
public void run() {
frm = new JFrame("Kitchen Sink");
Display.init(frm.getContentPane());
Display.getInstance().setProperty("package_name", "com.codename1.demos.kitchen");
Display.getInstance().setProperty("AppName", "KitchenSink");
Display.getInstance().setProperty("AppVersion", "2.0");
Display.getInstance().setProperty("Platform", System.getProperty("os.name"));
Display.getInstance().setProperty("OSVer", System.getProperty("os.version"));
frm.setDefaultCloseOperation(JFrame.DO_NOTHING_ON_CLOSE);
java.awt.Dimension d = new java.awt.Dimension(APP_WIDTH, APP_HEIGHT);
frm.getContentPane().setPreferredSize(d);
frm.getContentPane().setMinimumSize(d);
frm.getContentPane().setMaximumSize(d);
frm.pack();
frm.addWindowListener(new WindowAdapter() {
@Override
public void windowClosing(WindowEvent e) {
Display.getInstance().callSerially(new Runnable() {
@Override
public void run() {
KitchenSinkStub (Desktop)
SwingUtilities.invokeLater(new KitchenSinkStub());
}
@Override
public void run() {
frm = new JFrame("Kitchen Sink");
Display.init(frm.getContentPane());
Display.getInstance().setProperty("package_name", "com.codename1.demos.kitchen");
Display.getInstance().setProperty("AppName", "KitchenSink");
Display.getInstance().setProperty("AppVersion", "2.0");
Display.getInstance().setProperty("Platform", System.getProperty("os.name"));
Display.getInstance().setProperty("OSVer", System.getProperty("os.version"));
frm.setDefaultCloseOperation(JFrame.DO_NOTHING_ON_CLOSE);
java.awt.Dimension d = new java.awt.Dimension(APP_WIDTH, APP_HEIGHT);
frm.getContentPane().setPreferredSize(d);
frm.getContentPane().setMinimumSize(d);
frm.getContentPane().setMaximumSize(d);
frm.pack();
frm.addWindowListener(new WindowAdapter() {
@Override
public void windowClosing(WindowEvent e) {
Display.getInstance().callSerially(new Runnable() {
@Override
public void run() {
KitchenSinkStub (Desktop)
frm.pack();
frm.addWindowListener(new WindowAdapter() {
@Override
public void windowClosing(WindowEvent e) {
Display.getInstance().callSerially(new Runnable() {
@Override
public void run() {
mainApp.stop();
mainApp.destroy();
Display.getInstance().exitApplication();
}
});
}
} );
Display.getInstance().callSerially(new Runnable() {
@Override
public void run() {
if(Display.getInstance().isEdt()) {
mainApp = new com.codename1.demos.kitchen.KitchenSink();
mainApp.init(this);
mainApp.start();
SwingUtilities.invokeLater(this);
} else {
frm.setVisible(true);
KitchenSinkStub (Desktop)
@Override
public void run() {
mainApp.stop();
mainApp.destroy();
Display.getInstance().exitApplication();
}
});
}
} );
Display.getInstance().callSerially(new Runnable() {
@Override
public void run() {
if(Display.getInstance().isEdt()) {
mainApp = new com.codename1.demos.kitchen.KitchenSink();
mainApp.init(this);
mainApp.start();
SwingUtilities.invokeLater(this);
} else {
frm.setVisible(true);
}
}
});
}
}
KitchenSinkStub (Desktop)
<target name="desktop" depends="init">
<delete dir="build/tmp" />
<mkdir dir="build/tmp" />
<javac destdir="build/tmp"
encoding="${source.encoding}"
source="1.8"
target="1.8"
classpath="JavaSE.jar">
<src path="${src.dir}:stubs/desktop"/>
</javac>
<copy file="../cn1/Themes/iOS7Theme.res" todir="build/tmp" />
<jar jarfile="kitchesink-desktop.jar">
<manifest> <5>
<attribute name="Main-Class"
value="com.codename1.demos.kitchen.KitchenSinkStub"/>
</manifest>
<fileset dir="../cn1/Ports/JavaSE/build/classes" excludes="*.skin" />
<fileset dir="build/tmp" />
<fileset dir="src" excludes="*.java" />
</jar>
</target>
build.xml
<target name="desktop" depends="init">
<delete dir="build/tmp" />
<mkdir dir="build/tmp" />
<javac destdir="build/tmp"
encoding="${source.encoding}"
source="1.8"
target="1.8"
classpath="JavaSE.jar">
<src path="${src.dir}:stubs/desktop"/>
</javac>
<copy file="../cn1/Themes/iOS7Theme.res" todir="build/tmp" />
<jar jarfile="kitchesink-desktop.jar">
<manifest> <5>
<attribute name="Main-Class"
value="com.codename1.demos.kitchen.KitchenSinkStub"/>
</manifest>
<fileset dir="../cn1/Ports/JavaSE/build/classes" excludes="*.skin" />
<fileset dir="build/tmp" />
<fileset dir="src" excludes="*.java" />
</jar>
</target>
build.xml
<target name="desktop" depends="init">
<delete dir="build/tmp" />
<mkdir dir="build/tmp" />
<javac destdir="build/tmp"
encoding="${source.encoding}"
source="1.8"
target="1.8"
classpath="JavaSE.jar">
<src path="${src.dir}:stubs/desktop"/>
</javac>
<copy file="../cn1/Themes/iOS7Theme.res" todir="build/tmp" />
<jar jarfile="kitchesink-desktop.jar">
<manifest> <5>
<attribute name="Main-Class"
value="com.codename1.demos.kitchen.KitchenSinkStub"/>
</manifest>
<fileset dir="../cn1/Ports/JavaSE/build/classes" excludes="*.skin" />
<fileset dir="build/tmp" />
<fileset dir="src" excludes="*.java" />
</jar>
</target>
build.xml
<target name="desktop" depends="init">
<delete dir="build/tmp" />
<mkdir dir="build/tmp" />
<javac destdir="build/tmp"
encoding="${source.encoding}"
source="1.8"
target="1.8"
classpath="JavaSE.jar">
<src path="${src.dir}:stubs/desktop"/>
</javac>
<copy file="../cn1/Themes/iOS7Theme.res" todir="build/tmp" />
<jar jarfile="kitchesink-desktop.jar">
<manifest> <5>
<attribute name="Main-Class"
value="com.codename1.demos.kitchen.KitchenSinkStub"/>
</manifest>
<fileset dir="../cn1/Ports/JavaSE/build/classes" excludes="*.skin" />
<fileset dir="build/tmp" />
<fileset dir="src" excludes="*.java" />
</jar>
</target>
build.xml
<target name="desktop" depends="init">
<delete dir="build/tmp" />
<mkdir dir="build/tmp" />
<javac destdir="build/tmp"
encoding="${source.encoding}"
source="1.8"
target="1.8"
classpath="JavaSE.jar">
<src path="${src.dir}:stubs/desktop"/>
</javac>
<copy file="../cn1/Themes/iOS7Theme.res" todir="build/tmp" />
<jar jarfile="kitchesink-desktop.jar">
<manifest> <5>
<attribute name="Main-Class"
value="com.codename1.demos.kitchen.KitchenSinkStub"/>
</manifest>
<fileset dir="../cn1/Ports/JavaSE/build/classes" excludes="*.skin" />
<fileset dir="build/tmp" />
<fileset dir="src" excludes="*.java" />
</jar>
</target>
build.xml
<target name="desktop" depends="init">
<delete dir="build/tmp" />
<mkdir dir="build/tmp" />
<javac destdir="build/tmp"
encoding="${source.encoding}"
source="1.8"
target="1.8"
classpath="JavaSE.jar">
<src path="${src.dir}:stubs/desktop"/>
</javac>
<copy file="../cn1/Themes/iOS7Theme.res" todir="build/tmp" />
<jar jarfile="kitchesink-desktop.jar">
<manifest> <5>
<attribute name="Main-Class"
value="com.codename1.demos.kitchen.KitchenSinkStub"/>
</manifest>
<fileset dir="../cn1/Ports/JavaSE/build/classes" excludes="*.skin" />
<fileset dir="build/tmp" />
<fileset dir="src" excludes="*.java" />
</jar>
</target>
build.xml
<target name="desktop" depends="init">
<delete dir="build/tmp" />
<mkdir dir="build/tmp" />
<javac destdir="build/tmp"
encoding="${source.encoding}"
source="1.8"
target="1.8"
classpath="JavaSE.jar">
<src path="${src.dir}:stubs/desktop"/>
</javac>
<copy file="../cn1/Themes/iOS7Theme.res" todir="build/tmp" />
<jar jarfile="kitchesink-desktop.jar">
<manifest> <5>
<attribute name="Main-Class"
value="com.codename1.demos.kitchen.KitchenSinkStub"/>
</manifest>
<fileset dir="../cn1/Ports/JavaSE/build/classes" excludes="*.skin" />
<fileset dir="build/tmp" />
<fileset dir="src" excludes="*.java" />
</jar>
</target>
build.xml
<target name="desktop" depends="init">
<delete dir="build/tmp" />
<mkdir dir="build/tmp" />
<javac destdir="build/tmp"
encoding="${source.encoding}"
source="1.8"
target="1.8"
classpath="JavaSE.jar">
<src path="${src.dir}:stubs/desktop"/>
</javac>
<copy file="../cn1/Themes/iOS7Theme.res" todir="build/tmp" />
<jar jarfile="kitchesink-desktop.jar">
<manifest> <5>
<attribute name="Main-Class"
value="com.codename1.demos.kitchen.KitchenSinkStub"/>
</manifest>
<fileset dir="../cn1/Ports/JavaSE/build/classes" excludes="*.skin" />
<fileset dir="build/tmp" />
<fileset dir="src" excludes="*.java" />
</jar>
</target>
build.xml
java -jar kitchesink-desktop.jar
Run

More Related Content

Similar to Hacking the Codename One Source Code - Part III.pdf

In Java Write a GUI application to simulate writing out a check. The.pdf
In Java Write a GUI application to simulate writing out a check. The.pdfIn Java Write a GUI application to simulate writing out a check. The.pdf
In Java Write a GUI application to simulate writing out a check. The.pdfflashfashioncasualwe
 
codigomenu-1 (1).docx
codigomenu-1 (1).docxcodigomenu-1 (1).docx
codigomenu-1 (1).docxAnaLpez275
 
codigomenu-1.docx
codigomenu-1.docxcodigomenu-1.docx
codigomenu-1.docxAnaLpez275
 
Write a GUI application to simulate writing out a check. The value o.pdf
Write a GUI application to simulate writing out a check. The value o.pdfWrite a GUI application to simulate writing out a check. The value o.pdf
Write a GUI application to simulate writing out a check. The value o.pdffathimaoptical
 
ViewerFrame.java import javax.swing.JFrame;public class Viewer.pdf
ViewerFrame.java import javax.swing.JFrame;public class Viewer.pdfViewerFrame.java import javax.swing.JFrame;public class Viewer.pdf
ViewerFrame.java import javax.swing.JFrame;public class Viewer.pdfannaindustries
 
Main class --------------------------import java.awt.FlowLayout.pdf
Main class --------------------------import java.awt.FlowLayout.pdfMain class --------------------------import java.awt.FlowLayout.pdf
Main class --------------------------import java.awt.FlowLayout.pdfanushkaent7
 
Improving android experience for both users and developers
Improving android experience for both users and developersImproving android experience for both users and developers
Improving android experience for both users and developersPavel Lahoda
 
Droidcon2013 android experience lahoda
Droidcon2013 android experience lahodaDroidcon2013 android experience lahoda
Droidcon2013 android experience lahodaDroidcon Berlin
 
Phone gap 12 things you should know
Phone gap 12 things you should knowPhone gap 12 things you should know
Phone gap 12 things you should knowISOCHK
 
MARY WORD CONCERINGNDATA SCIENCE PROGRAMS FOR UNDERGRADUATE STUDENT
MARY WORD CONCERINGNDATA SCIENCE PROGRAMS FOR UNDERGRADUATE STUDENTMARY WORD CONCERINGNDATA SCIENCE PROGRAMS FOR UNDERGRADUATE STUDENT
MARY WORD CONCERINGNDATA SCIENCE PROGRAMS FOR UNDERGRADUATE STUDENTjohnmutiso245
 
Groovy-er desktop applications with Griffon
Groovy-er desktop applications with GriffonGroovy-er desktop applications with Griffon
Groovy-er desktop applications with GriffonEric Wendelin
 
Groovy-er Desktop Applications With Griffon
Groovy-er Desktop Applications With GriffonGroovy-er Desktop Applications With Griffon
Groovy-er Desktop Applications With GriffonMatthew McCullough
 
correct the error and add code same in the pic import jav.pdf
correct the error and add code same in the pic   import jav.pdfcorrect the error and add code same in the pic   import jav.pdf
correct the error and add code same in the pic import jav.pdfdevangmittal4
 

Similar to Hacking the Codename One Source Code - Part III.pdf (20)

In Java Write a GUI application to simulate writing out a check. The.pdf
In Java Write a GUI application to simulate writing out a check. The.pdfIn Java Write a GUI application to simulate writing out a check. The.pdf
In Java Write a GUI application to simulate writing out a check. The.pdf
 
codigomenu-1 (1).docx
codigomenu-1 (1).docxcodigomenu-1 (1).docx
codigomenu-1 (1).docx
 
codigomenu-1.docx
codigomenu-1.docxcodigomenu-1.docx
codigomenu-1.docx
 
Write a GUI application to simulate writing out a check. The value o.pdf
Write a GUI application to simulate writing out a check. The value o.pdfWrite a GUI application to simulate writing out a check. The value o.pdf
Write a GUI application to simulate writing out a check. The value o.pdf
 
Wicket 6
Wicket 6Wicket 6
Wicket 6
 
From Swing to JavaFX
From Swing to JavaFXFrom Swing to JavaFX
From Swing to JavaFX
 
ViewerFrame.java import javax.swing.JFrame;public class Viewer.pdf
ViewerFrame.java import javax.swing.JFrame;public class Viewer.pdfViewerFrame.java import javax.swing.JFrame;public class Viewer.pdf
ViewerFrame.java import javax.swing.JFrame;public class Viewer.pdf
 
Main class --------------------------import java.awt.FlowLayout.pdf
Main class --------------------------import java.awt.FlowLayout.pdfMain class --------------------------import java.awt.FlowLayout.pdf
Main class --------------------------import java.awt.FlowLayout.pdf
 
Test
TestTest
Test
 
Improving android experience for both users and developers
Improving android experience for both users and developersImproving android experience for both users and developers
Improving android experience for both users and developers
 
Droidcon2013 android experience lahoda
Droidcon2013 android experience lahodaDroidcon2013 android experience lahoda
Droidcon2013 android experience lahoda
 
Phone gap 12 things you should know
Phone gap 12 things you should knowPhone gap 12 things you should know
Phone gap 12 things you should know
 
package org dev
package org devpackage org dev
package org dev
 
Package org dev
Package org devPackage org dev
Package org dev
 
MARY WORD CONCERINGNDATA SCIENCE PROGRAMS FOR UNDERGRADUATE STUDENT
MARY WORD CONCERINGNDATA SCIENCE PROGRAMS FOR UNDERGRADUATE STUDENTMARY WORD CONCERINGNDATA SCIENCE PROGRAMS FOR UNDERGRADUATE STUDENT
MARY WORD CONCERINGNDATA SCIENCE PROGRAMS FOR UNDERGRADUATE STUDENT
 
Groovy-er desktop applications with Griffon
Groovy-er desktop applications with GriffonGroovy-er desktop applications with Griffon
Groovy-er desktop applications with Griffon
 
Groovy-er Desktop Applications With Griffon
Groovy-er Desktop Applications With GriffonGroovy-er Desktop Applications With Griffon
Groovy-er Desktop Applications With Griffon
 
Java awt
Java awtJava awt
Java awt
 
correct the error and add code same in the pic import jav.pdf
correct the error and add code same in the pic   import jav.pdfcorrect the error and add code same in the pic   import jav.pdf
correct the error and add code same in the pic import jav.pdf
 
TY.BSc.IT Java QB U2
TY.BSc.IT Java QB U2TY.BSc.IT Java QB U2
TY.BSc.IT Java QB U2
 

More from ShaiAlmog1

The Duck Teaches Learn to debug from the masters. Local to production- kill ...
The Duck Teaches  Learn to debug from the masters. Local to production- kill ...The Duck Teaches  Learn to debug from the masters. Local to production- kill ...
The Duck Teaches Learn to debug from the masters. Local to production- kill ...ShaiAlmog1
 
create-netflix-clone-06-client-ui.pdf
create-netflix-clone-06-client-ui.pdfcreate-netflix-clone-06-client-ui.pdf
create-netflix-clone-06-client-ui.pdfShaiAlmog1
 
create-netflix-clone-01-introduction_transcript.pdf
create-netflix-clone-01-introduction_transcript.pdfcreate-netflix-clone-01-introduction_transcript.pdf
create-netflix-clone-01-introduction_transcript.pdfShaiAlmog1
 
create-netflix-clone-02-server_transcript.pdf
create-netflix-clone-02-server_transcript.pdfcreate-netflix-clone-02-server_transcript.pdf
create-netflix-clone-02-server_transcript.pdfShaiAlmog1
 
create-netflix-clone-04-server-continued_transcript.pdf
create-netflix-clone-04-server-continued_transcript.pdfcreate-netflix-clone-04-server-continued_transcript.pdf
create-netflix-clone-04-server-continued_transcript.pdfShaiAlmog1
 
create-netflix-clone-01-introduction.pdf
create-netflix-clone-01-introduction.pdfcreate-netflix-clone-01-introduction.pdf
create-netflix-clone-01-introduction.pdfShaiAlmog1
 
create-netflix-clone-06-client-ui_transcript.pdf
create-netflix-clone-06-client-ui_transcript.pdfcreate-netflix-clone-06-client-ui_transcript.pdf
create-netflix-clone-06-client-ui_transcript.pdfShaiAlmog1
 
create-netflix-clone-03-server.pdf
create-netflix-clone-03-server.pdfcreate-netflix-clone-03-server.pdf
create-netflix-clone-03-server.pdfShaiAlmog1
 
create-netflix-clone-04-server-continued.pdf
create-netflix-clone-04-server-continued.pdfcreate-netflix-clone-04-server-continued.pdf
create-netflix-clone-04-server-continued.pdfShaiAlmog1
 
create-netflix-clone-05-client-model_transcript.pdf
create-netflix-clone-05-client-model_transcript.pdfcreate-netflix-clone-05-client-model_transcript.pdf
create-netflix-clone-05-client-model_transcript.pdfShaiAlmog1
 
create-netflix-clone-03-server_transcript.pdf
create-netflix-clone-03-server_transcript.pdfcreate-netflix-clone-03-server_transcript.pdf
create-netflix-clone-03-server_transcript.pdfShaiAlmog1
 
create-netflix-clone-02-server.pdf
create-netflix-clone-02-server.pdfcreate-netflix-clone-02-server.pdf
create-netflix-clone-02-server.pdfShaiAlmog1
 
create-netflix-clone-05-client-model.pdf
create-netflix-clone-05-client-model.pdfcreate-netflix-clone-05-client-model.pdf
create-netflix-clone-05-client-model.pdfShaiAlmog1
 
Creating a Whatsapp Clone - Part II.pdf
Creating a Whatsapp Clone - Part II.pdfCreating a Whatsapp Clone - Part II.pdf
Creating a Whatsapp Clone - Part II.pdfShaiAlmog1
 
Creating a Whatsapp Clone - Part IX - Transcript.pdf
Creating a Whatsapp Clone - Part IX - Transcript.pdfCreating a Whatsapp Clone - Part IX - Transcript.pdf
Creating a Whatsapp Clone - Part IX - Transcript.pdfShaiAlmog1
 
Creating a Whatsapp Clone - Part II - Transcript.pdf
Creating a Whatsapp Clone - Part II - Transcript.pdfCreating a Whatsapp Clone - Part II - Transcript.pdf
Creating a Whatsapp Clone - Part II - Transcript.pdfShaiAlmog1
 
Creating a Whatsapp Clone - Part V - Transcript.pdf
Creating a Whatsapp Clone - Part V - Transcript.pdfCreating a Whatsapp Clone - Part V - Transcript.pdf
Creating a Whatsapp Clone - Part V - Transcript.pdfShaiAlmog1
 
Creating a Whatsapp Clone - Part IV - Transcript.pdf
Creating a Whatsapp Clone - Part IV - Transcript.pdfCreating a Whatsapp Clone - Part IV - Transcript.pdf
Creating a Whatsapp Clone - Part IV - Transcript.pdfShaiAlmog1
 
Creating a Whatsapp Clone - Part IV.pdf
Creating a Whatsapp Clone - Part IV.pdfCreating a Whatsapp Clone - Part IV.pdf
Creating a Whatsapp Clone - Part IV.pdfShaiAlmog1
 
Creating a Whatsapp Clone - Part I - Transcript.pdf
Creating a Whatsapp Clone - Part I - Transcript.pdfCreating a Whatsapp Clone - Part I - Transcript.pdf
Creating a Whatsapp Clone - Part I - Transcript.pdfShaiAlmog1
 

More from ShaiAlmog1 (20)

The Duck Teaches Learn to debug from the masters. Local to production- kill ...
The Duck Teaches  Learn to debug from the masters. Local to production- kill ...The Duck Teaches  Learn to debug from the masters. Local to production- kill ...
The Duck Teaches Learn to debug from the masters. Local to production- kill ...
 
create-netflix-clone-06-client-ui.pdf
create-netflix-clone-06-client-ui.pdfcreate-netflix-clone-06-client-ui.pdf
create-netflix-clone-06-client-ui.pdf
 
create-netflix-clone-01-introduction_transcript.pdf
create-netflix-clone-01-introduction_transcript.pdfcreate-netflix-clone-01-introduction_transcript.pdf
create-netflix-clone-01-introduction_transcript.pdf
 
create-netflix-clone-02-server_transcript.pdf
create-netflix-clone-02-server_transcript.pdfcreate-netflix-clone-02-server_transcript.pdf
create-netflix-clone-02-server_transcript.pdf
 
create-netflix-clone-04-server-continued_transcript.pdf
create-netflix-clone-04-server-continued_transcript.pdfcreate-netflix-clone-04-server-continued_transcript.pdf
create-netflix-clone-04-server-continued_transcript.pdf
 
create-netflix-clone-01-introduction.pdf
create-netflix-clone-01-introduction.pdfcreate-netflix-clone-01-introduction.pdf
create-netflix-clone-01-introduction.pdf
 
create-netflix-clone-06-client-ui_transcript.pdf
create-netflix-clone-06-client-ui_transcript.pdfcreate-netflix-clone-06-client-ui_transcript.pdf
create-netflix-clone-06-client-ui_transcript.pdf
 
create-netflix-clone-03-server.pdf
create-netflix-clone-03-server.pdfcreate-netflix-clone-03-server.pdf
create-netflix-clone-03-server.pdf
 
create-netflix-clone-04-server-continued.pdf
create-netflix-clone-04-server-continued.pdfcreate-netflix-clone-04-server-continued.pdf
create-netflix-clone-04-server-continued.pdf
 
create-netflix-clone-05-client-model_transcript.pdf
create-netflix-clone-05-client-model_transcript.pdfcreate-netflix-clone-05-client-model_transcript.pdf
create-netflix-clone-05-client-model_transcript.pdf
 
create-netflix-clone-03-server_transcript.pdf
create-netflix-clone-03-server_transcript.pdfcreate-netflix-clone-03-server_transcript.pdf
create-netflix-clone-03-server_transcript.pdf
 
create-netflix-clone-02-server.pdf
create-netflix-clone-02-server.pdfcreate-netflix-clone-02-server.pdf
create-netflix-clone-02-server.pdf
 
create-netflix-clone-05-client-model.pdf
create-netflix-clone-05-client-model.pdfcreate-netflix-clone-05-client-model.pdf
create-netflix-clone-05-client-model.pdf
 
Creating a Whatsapp Clone - Part II.pdf
Creating a Whatsapp Clone - Part II.pdfCreating a Whatsapp Clone - Part II.pdf
Creating a Whatsapp Clone - Part II.pdf
 
Creating a Whatsapp Clone - Part IX - Transcript.pdf
Creating a Whatsapp Clone - Part IX - Transcript.pdfCreating a Whatsapp Clone - Part IX - Transcript.pdf
Creating a Whatsapp Clone - Part IX - Transcript.pdf
 
Creating a Whatsapp Clone - Part II - Transcript.pdf
Creating a Whatsapp Clone - Part II - Transcript.pdfCreating a Whatsapp Clone - Part II - Transcript.pdf
Creating a Whatsapp Clone - Part II - Transcript.pdf
 
Creating a Whatsapp Clone - Part V - Transcript.pdf
Creating a Whatsapp Clone - Part V - Transcript.pdfCreating a Whatsapp Clone - Part V - Transcript.pdf
Creating a Whatsapp Clone - Part V - Transcript.pdf
 
Creating a Whatsapp Clone - Part IV - Transcript.pdf
Creating a Whatsapp Clone - Part IV - Transcript.pdfCreating a Whatsapp Clone - Part IV - Transcript.pdf
Creating a Whatsapp Clone - Part IV - Transcript.pdf
 
Creating a Whatsapp Clone - Part IV.pdf
Creating a Whatsapp Clone - Part IV.pdfCreating a Whatsapp Clone - Part IV.pdf
Creating a Whatsapp Clone - Part IV.pdf
 
Creating a Whatsapp Clone - Part I - Transcript.pdf
Creating a Whatsapp Clone - Part I - Transcript.pdfCreating a Whatsapp Clone - Part I - Transcript.pdf
Creating a Whatsapp Clone - Part I - Transcript.pdf
 

Recently uploaded

Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...
Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...
Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...Skynet Technologies
 
Tales from a Passkey Provider Progress from Awareness to Implementation.pptx
Tales from a Passkey Provider  Progress from Awareness to Implementation.pptxTales from a Passkey Provider  Progress from Awareness to Implementation.pptx
Tales from a Passkey Provider Progress from Awareness to Implementation.pptxFIDO Alliance
 
Google I/O Extended 2024 Warsaw
Google I/O Extended 2024 WarsawGoogle I/O Extended 2024 Warsaw
Google I/O Extended 2024 WarsawGDSC PJATK
 
Microsoft CSP Briefing Pre-Engagement - Questionnaire
Microsoft CSP Briefing Pre-Engagement - QuestionnaireMicrosoft CSP Briefing Pre-Engagement - Questionnaire
Microsoft CSP Briefing Pre-Engagement - QuestionnaireExakis Nelite
 
State of the Smart Building Startup Landscape 2024!
State of the Smart Building Startup Landscape 2024!State of the Smart Building Startup Landscape 2024!
State of the Smart Building Startup Landscape 2024!Memoori
 
Hyatt driving innovation and exceptional customer experiences with FIDO passw...
Hyatt driving innovation and exceptional customer experiences with FIDO passw...Hyatt driving innovation and exceptional customer experiences with FIDO passw...
Hyatt driving innovation and exceptional customer experiences with FIDO passw...FIDO Alliance
 
ChatGPT and Beyond - Elevating DevOps Productivity
ChatGPT and Beyond - Elevating DevOps ProductivityChatGPT and Beyond - Elevating DevOps Productivity
ChatGPT and Beyond - Elevating DevOps ProductivityVictorSzoltysek
 
CORS (Kitworks Team Study 양다윗 발표자료 240510)
CORS (Kitworks Team Study 양다윗 발표자료 240510)CORS (Kitworks Team Study 양다윗 발표자료 240510)
CORS (Kitworks Team Study 양다윗 발표자료 240510)Wonjun Hwang
 
UiPath manufacturing technology benefits and AI overview
UiPath manufacturing technology benefits and AI overviewUiPath manufacturing technology benefits and AI overview
UiPath manufacturing technology benefits and AI overviewDianaGray10
 
Design and Development of a Provenance Capture Platform for Data Science
Design and Development of a Provenance Capture Platform for Data ScienceDesign and Development of a Provenance Capture Platform for Data Science
Design and Development of a Provenance Capture Platform for Data SciencePaolo Missier
 
How to Check CNIC Information Online with Pakdata cf
How to Check CNIC Information Online with Pakdata cfHow to Check CNIC Information Online with Pakdata cf
How to Check CNIC Information Online with Pakdata cfdanishmna97
 
Observability Concepts EVERY Developer Should Know (DevOpsDays Seattle)
Observability Concepts EVERY Developer Should Know (DevOpsDays Seattle)Observability Concepts EVERY Developer Should Know (DevOpsDays Seattle)
Observability Concepts EVERY Developer Should Know (DevOpsDays Seattle)Paige Cruz
 
2024 May Patch Tuesday
2024 May Patch Tuesday2024 May Patch Tuesday
2024 May Patch TuesdayIvanti
 
Continuing Bonds Through AI: A Hermeneutic Reflection on Thanabots
Continuing Bonds Through AI: A Hermeneutic Reflection on ThanabotsContinuing Bonds Through AI: A Hermeneutic Reflection on Thanabots
Continuing Bonds Through AI: A Hermeneutic Reflection on ThanabotsLeah Henrickson
 
How we scaled to 80K users by doing nothing!.pdf
How we scaled to 80K users by doing nothing!.pdfHow we scaled to 80K users by doing nothing!.pdf
How we scaled to 80K users by doing nothing!.pdfSrushith Repakula
 
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...TrustArc
 
Introduction to use of FHIR Documents in ABDM
Introduction to use of FHIR Documents in ABDMIntroduction to use of FHIR Documents in ABDM
Introduction to use of FHIR Documents in ABDMKumar Satyam
 
Working together SRE & Platform Engineering
Working together SRE & Platform EngineeringWorking together SRE & Platform Engineering
Working together SRE & Platform EngineeringMarcus Vechiato
 
الأمن السيبراني - ما لا يسع للمستخدم جهله
الأمن السيبراني - ما لا يسع للمستخدم جهلهالأمن السيبراني - ما لا يسع للمستخدم جهله
الأمن السيبراني - ما لا يسع للمستخدم جهلهMohamed Sweelam
 
Generative AI Use Cases and Applications.pdf
Generative AI Use Cases and Applications.pdfGenerative AI Use Cases and Applications.pdf
Generative AI Use Cases and Applications.pdfalexjohnson7307
 

Recently uploaded (20)

Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...
Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...
Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...
 
Tales from a Passkey Provider Progress from Awareness to Implementation.pptx
Tales from a Passkey Provider  Progress from Awareness to Implementation.pptxTales from a Passkey Provider  Progress from Awareness to Implementation.pptx
Tales from a Passkey Provider Progress from Awareness to Implementation.pptx
 
Google I/O Extended 2024 Warsaw
Google I/O Extended 2024 WarsawGoogle I/O Extended 2024 Warsaw
Google I/O Extended 2024 Warsaw
 
Microsoft CSP Briefing Pre-Engagement - Questionnaire
Microsoft CSP Briefing Pre-Engagement - QuestionnaireMicrosoft CSP Briefing Pre-Engagement - Questionnaire
Microsoft CSP Briefing Pre-Engagement - Questionnaire
 
State of the Smart Building Startup Landscape 2024!
State of the Smart Building Startup Landscape 2024!State of the Smart Building Startup Landscape 2024!
State of the Smart Building Startup Landscape 2024!
 
Hyatt driving innovation and exceptional customer experiences with FIDO passw...
Hyatt driving innovation and exceptional customer experiences with FIDO passw...Hyatt driving innovation and exceptional customer experiences with FIDO passw...
Hyatt driving innovation and exceptional customer experiences with FIDO passw...
 
ChatGPT and Beyond - Elevating DevOps Productivity
ChatGPT and Beyond - Elevating DevOps ProductivityChatGPT and Beyond - Elevating DevOps Productivity
ChatGPT and Beyond - Elevating DevOps Productivity
 
CORS (Kitworks Team Study 양다윗 발표자료 240510)
CORS (Kitworks Team Study 양다윗 발표자료 240510)CORS (Kitworks Team Study 양다윗 발표자료 240510)
CORS (Kitworks Team Study 양다윗 발표자료 240510)
 
UiPath manufacturing technology benefits and AI overview
UiPath manufacturing technology benefits and AI overviewUiPath manufacturing technology benefits and AI overview
UiPath manufacturing technology benefits and AI overview
 
Design and Development of a Provenance Capture Platform for Data Science
Design and Development of a Provenance Capture Platform for Data ScienceDesign and Development of a Provenance Capture Platform for Data Science
Design and Development of a Provenance Capture Platform for Data Science
 
How to Check CNIC Information Online with Pakdata cf
How to Check CNIC Information Online with Pakdata cfHow to Check CNIC Information Online with Pakdata cf
How to Check CNIC Information Online with Pakdata cf
 
Observability Concepts EVERY Developer Should Know (DevOpsDays Seattle)
Observability Concepts EVERY Developer Should Know (DevOpsDays Seattle)Observability Concepts EVERY Developer Should Know (DevOpsDays Seattle)
Observability Concepts EVERY Developer Should Know (DevOpsDays Seattle)
 
2024 May Patch Tuesday
2024 May Patch Tuesday2024 May Patch Tuesday
2024 May Patch Tuesday
 
Continuing Bonds Through AI: A Hermeneutic Reflection on Thanabots
Continuing Bonds Through AI: A Hermeneutic Reflection on ThanabotsContinuing Bonds Through AI: A Hermeneutic Reflection on Thanabots
Continuing Bonds Through AI: A Hermeneutic Reflection on Thanabots
 
How we scaled to 80K users by doing nothing!.pdf
How we scaled to 80K users by doing nothing!.pdfHow we scaled to 80K users by doing nothing!.pdf
How we scaled to 80K users by doing nothing!.pdf
 
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
 
Introduction to use of FHIR Documents in ABDM
Introduction to use of FHIR Documents in ABDMIntroduction to use of FHIR Documents in ABDM
Introduction to use of FHIR Documents in ABDM
 
Working together SRE & Platform Engineering
Working together SRE & Platform EngineeringWorking together SRE & Platform Engineering
Working together SRE & Platform Engineering
 
الأمن السيبراني - ما لا يسع للمستخدم جهله
الأمن السيبراني - ما لا يسع للمستخدم جهلهالأمن السيبراني - ما لا يسع للمستخدم جهله
الأمن السيبراني - ما لا يسع للمستخدم جهله
 
Generative AI Use Cases and Applications.pdf
Generative AI Use Cases and Applications.pdfGenerative AI Use Cases and Applications.pdf
Generative AI Use Cases and Applications.pdf
 

Hacking the Codename One Source Code - Part III.pdf

  • 1. Hacking the Source - Part III
  • 2. package com.codename1.demos.kitchen; import com.codename1.impl.javase.JavaSEPort; import com.codename1.ui.Display; import java.awt.event.WindowAdapter; import java.awt.event.WindowEvent; import javax.swing.JFrame; import javax.swing.SwingUtilities; public class KitchenSinkStub implements Runnable { private static JFrame frm; private KitchenSink mainApp; private static final int APP_WIDTH = 800; private static final int APP_HEIGHT = 600; public static void main(String[] args) { JavaSEPort.setNativeTheme("/iOS7Theme.res"); JavaSEPort.blockMonitors(); JavaSEPort.setShowEDTViolationStacks(false); JavaSEPort.setShowEDTWarnings(false); JavaSEPort.setAppHomeDir(".KitchenSink"); JavaSEPort.setExposeFilesystem(true); JavaSEPort.setTablet(true); JavaSEPort.setUseNativeInput(true); JavaSEPort.setDefaultPixelMilliRatio(new Double(10)); SwingUtilities.invokeLater(new KitchenSinkStub()); } KitchenSinkStub (Desktop)
  • 3. package com.codename1.demos.kitchen; import com.codename1.impl.javase.JavaSEPort; import com.codename1.ui.Display; import java.awt.event.WindowAdapter; import java.awt.event.WindowEvent; import javax.swing.JFrame; import javax.swing.SwingUtilities; public class KitchenSinkStub implements Runnable { private static JFrame frm; private KitchenSink mainApp; private static final int APP_WIDTH = 800; private static final int APP_HEIGHT = 600; public static void main(String[] args) { JavaSEPort.setNativeTheme("/iOS7Theme.res"); JavaSEPort.blockMonitors(); JavaSEPort.setShowEDTViolationStacks(false); JavaSEPort.setShowEDTWarnings(false); JavaSEPort.setAppHomeDir(".KitchenSink"); JavaSEPort.setExposeFilesystem(true); JavaSEPort.setTablet(true); JavaSEPort.setUseNativeInput(true); JavaSEPort.setDefaultPixelMilliRatio(new Double(10)); SwingUtilities.invokeLater(new KitchenSinkStub()); } KitchenSinkStub (Desktop)
  • 4. package com.codename1.demos.kitchen; import com.codename1.impl.javase.JavaSEPort; import com.codename1.ui.Display; import java.awt.event.WindowAdapter; import java.awt.event.WindowEvent; import javax.swing.JFrame; import javax.swing.SwingUtilities; public class KitchenSinkStub implements Runnable { private static JFrame frm; private KitchenSink mainApp; private static final int APP_WIDTH = 800; private static final int APP_HEIGHT = 600; public static void main(String[] args) { JavaSEPort.setNativeTheme("/iOS7Theme.res"); JavaSEPort.blockMonitors(); JavaSEPort.setShowEDTViolationStacks(false); JavaSEPort.setShowEDTWarnings(false); JavaSEPort.setAppHomeDir(".KitchenSink"); JavaSEPort.setExposeFilesystem(true); JavaSEPort.setTablet(true); JavaSEPort.setUseNativeInput(true); JavaSEPort.setDefaultPixelMilliRatio(new Double(10)); SwingUtilities.invokeLater(new KitchenSinkStub()); } KitchenSinkStub (Desktop)
  • 5. package com.codename1.demos.kitchen; import com.codename1.impl.javase.JavaSEPort; import com.codename1.ui.Display; import java.awt.event.WindowAdapter; import java.awt.event.WindowEvent; import javax.swing.JFrame; import javax.swing.SwingUtilities; public class KitchenSinkStub implements Runnable { private static JFrame frm; private KitchenSink mainApp; private static final int APP_WIDTH = 800; private static final int APP_HEIGHT = 600; public static void main(String[] args) { JavaSEPort.setNativeTheme("/iOS7Theme.res"); JavaSEPort.blockMonitors(); JavaSEPort.setShowEDTViolationStacks(false); JavaSEPort.setShowEDTWarnings(false); JavaSEPort.setAppHomeDir(".KitchenSink"); JavaSEPort.setExposeFilesystem(true); JavaSEPort.setTablet(true); JavaSEPort.setUseNativeInput(true); JavaSEPort.setDefaultPixelMilliRatio(new Double(10)); SwingUtilities.invokeLater(new KitchenSinkStub()); } KitchenSinkStub (Desktop)
  • 6. package com.codename1.demos.kitchen; import com.codename1.impl.javase.JavaSEPort; import com.codename1.ui.Display; import java.awt.event.WindowAdapter; import java.awt.event.WindowEvent; import javax.swing.JFrame; import javax.swing.SwingUtilities; public class KitchenSinkStub implements Runnable { private static JFrame frm; private KitchenSink mainApp; private static final int APP_WIDTH = 800; private static final int APP_HEIGHT = 600; public static void main(String[] args) { JavaSEPort.setNativeTheme("/iOS7Theme.res"); JavaSEPort.blockMonitors(); JavaSEPort.setShowEDTViolationStacks(false); JavaSEPort.setShowEDTWarnings(false); JavaSEPort.setAppHomeDir(".KitchenSink"); JavaSEPort.setExposeFilesystem(true); JavaSEPort.setTablet(true); JavaSEPort.setUseNativeInput(true); JavaSEPort.setDefaultPixelMilliRatio(new Double(10)); SwingUtilities.invokeLater(new KitchenSinkStub()); } KitchenSinkStub (Desktop)
  • 7. package com.codename1.demos.kitchen; import com.codename1.impl.javase.JavaSEPort; import com.codename1.ui.Display; import java.awt.event.WindowAdapter; import java.awt.event.WindowEvent; import javax.swing.JFrame; import javax.swing.SwingUtilities; public class KitchenSinkStub implements Runnable { private static JFrame frm; private KitchenSink mainApp; private static final int APP_WIDTH = 800; private static final int APP_HEIGHT = 600; public static void main(String[] args) { JavaSEPort.setNativeTheme("/iOS7Theme.res"); JavaSEPort.blockMonitors(); JavaSEPort.setShowEDTViolationStacks(false); JavaSEPort.setShowEDTWarnings(false); JavaSEPort.setAppHomeDir(".KitchenSink"); JavaSEPort.setExposeFilesystem(true); JavaSEPort.setTablet(true); JavaSEPort.setUseNativeInput(true); JavaSEPort.setDefaultPixelMilliRatio(new Double(10)); SwingUtilities.invokeLater(new KitchenSinkStub()); } KitchenSinkStub (Desktop)
  • 8. package com.codename1.demos.kitchen; import com.codename1.impl.javase.JavaSEPort; import com.codename1.ui.Display; import java.awt.event.WindowAdapter; import java.awt.event.WindowEvent; import javax.swing.JFrame; import javax.swing.SwingUtilities; public class KitchenSinkStub implements Runnable { private static JFrame frm; private KitchenSink mainApp; private static final int APP_WIDTH = 800; private static final int APP_HEIGHT = 600; public static void main(String[] args) { JavaSEPort.setNativeTheme("/iOS7Theme.res"); JavaSEPort.blockMonitors(); JavaSEPort.setShowEDTViolationStacks(false); JavaSEPort.setShowEDTWarnings(false); JavaSEPort.setAppHomeDir(".KitchenSink"); JavaSEPort.setExposeFilesystem(true); JavaSEPort.setTablet(true); JavaSEPort.setUseNativeInput(true); JavaSEPort.setDefaultPixelMilliRatio(new Double(10)); SwingUtilities.invokeLater(new KitchenSinkStub()); } KitchenSinkStub (Desktop)
  • 9. package com.codename1.demos.kitchen; import com.codename1.impl.javase.JavaSEPort; import com.codename1.ui.Display; import java.awt.event.WindowAdapter; import java.awt.event.WindowEvent; import javax.swing.JFrame; import javax.swing.SwingUtilities; public class KitchenSinkStub implements Runnable { private static JFrame frm; private KitchenSink mainApp; private static final int APP_WIDTH = 800; private static final int APP_HEIGHT = 600; public static void main(String[] args) { JavaSEPort.setNativeTheme("/iOS7Theme.res"); JavaSEPort.blockMonitors(); JavaSEPort.setShowEDTViolationStacks(false); JavaSEPort.setShowEDTWarnings(false); JavaSEPort.setAppHomeDir(".KitchenSink"); JavaSEPort.setExposeFilesystem(true); JavaSEPort.setTablet(true); JavaSEPort.setUseNativeInput(true); JavaSEPort.setDefaultPixelMilliRatio(new Double(10)); SwingUtilities.invokeLater(new KitchenSinkStub()); } KitchenSinkStub (Desktop)
  • 10. SwingUtilities.invokeLater(new KitchenSinkStub()); } @Override public void run() { frm = new JFrame("Kitchen Sink"); Display.init(frm.getContentPane()); Display.getInstance().setProperty("package_name", "com.codename1.demos.kitchen"); Display.getInstance().setProperty("AppName", "KitchenSink"); Display.getInstance().setProperty("AppVersion", "2.0"); Display.getInstance().setProperty("Platform", System.getProperty("os.name")); Display.getInstance().setProperty("OSVer", System.getProperty("os.version")); frm.setDefaultCloseOperation(JFrame.DO_NOTHING_ON_CLOSE); java.awt.Dimension d = new java.awt.Dimension(APP_WIDTH, APP_HEIGHT); frm.getContentPane().setPreferredSize(d); frm.getContentPane().setMinimumSize(d); frm.getContentPane().setMaximumSize(d); frm.pack(); frm.addWindowListener(new WindowAdapter() { @Override public void windowClosing(WindowEvent e) { Display.getInstance().callSerially(new Runnable() { @Override public void run() { KitchenSinkStub (Desktop)
  • 11. SwingUtilities.invokeLater(new KitchenSinkStub()); } @Override public void run() { frm = new JFrame("Kitchen Sink"); Display.init(frm.getContentPane()); Display.getInstance().setProperty("package_name", "com.codename1.demos.kitchen"); Display.getInstance().setProperty("AppName", "KitchenSink"); Display.getInstance().setProperty("AppVersion", "2.0"); Display.getInstance().setProperty("Platform", System.getProperty("os.name")); Display.getInstance().setProperty("OSVer", System.getProperty("os.version")); frm.setDefaultCloseOperation(JFrame.DO_NOTHING_ON_CLOSE); java.awt.Dimension d = new java.awt.Dimension(APP_WIDTH, APP_HEIGHT); frm.getContentPane().setPreferredSize(d); frm.getContentPane().setMinimumSize(d); frm.getContentPane().setMaximumSize(d); frm.pack(); frm.addWindowListener(new WindowAdapter() { @Override public void windowClosing(WindowEvent e) { Display.getInstance().callSerially(new Runnable() { @Override public void run() { KitchenSinkStub (Desktop)
  • 12. frm.pack(); frm.addWindowListener(new WindowAdapter() { @Override public void windowClosing(WindowEvent e) { Display.getInstance().callSerially(new Runnable() { @Override public void run() { mainApp.stop(); mainApp.destroy(); Display.getInstance().exitApplication(); } }); } } ); Display.getInstance().callSerially(new Runnable() { @Override public void run() { if(Display.getInstance().isEdt()) { mainApp = new com.codename1.demos.kitchen.KitchenSink(); mainApp.init(this); mainApp.start(); SwingUtilities.invokeLater(this); } else { frm.setVisible(true); KitchenSinkStub (Desktop)
  • 13. @Override public void run() { mainApp.stop(); mainApp.destroy(); Display.getInstance().exitApplication(); } }); } } ); Display.getInstance().callSerially(new Runnable() { @Override public void run() { if(Display.getInstance().isEdt()) { mainApp = new com.codename1.demos.kitchen.KitchenSink(); mainApp.init(this); mainApp.start(); SwingUtilities.invokeLater(this); } else { frm.setVisible(true); } } }); } } KitchenSinkStub (Desktop)
  • 14. <target name="desktop" depends="init"> <delete dir="build/tmp" /> <mkdir dir="build/tmp" /> <javac destdir="build/tmp" encoding="${source.encoding}" source="1.8" target="1.8" classpath="JavaSE.jar"> <src path="${src.dir}:stubs/desktop"/> </javac> <copy file="../cn1/Themes/iOS7Theme.res" todir="build/tmp" /> <jar jarfile="kitchesink-desktop.jar"> <manifest> <5> <attribute name="Main-Class" value="com.codename1.demos.kitchen.KitchenSinkStub"/> </manifest> <fileset dir="../cn1/Ports/JavaSE/build/classes" excludes="*.skin" /> <fileset dir="build/tmp" /> <fileset dir="src" excludes="*.java" /> </jar> </target> build.xml
  • 15. <target name="desktop" depends="init"> <delete dir="build/tmp" /> <mkdir dir="build/tmp" /> <javac destdir="build/tmp" encoding="${source.encoding}" source="1.8" target="1.8" classpath="JavaSE.jar"> <src path="${src.dir}:stubs/desktop"/> </javac> <copy file="../cn1/Themes/iOS7Theme.res" todir="build/tmp" /> <jar jarfile="kitchesink-desktop.jar"> <manifest> <5> <attribute name="Main-Class" value="com.codename1.demos.kitchen.KitchenSinkStub"/> </manifest> <fileset dir="../cn1/Ports/JavaSE/build/classes" excludes="*.skin" /> <fileset dir="build/tmp" /> <fileset dir="src" excludes="*.java" /> </jar> </target> build.xml
  • 16. <target name="desktop" depends="init"> <delete dir="build/tmp" /> <mkdir dir="build/tmp" /> <javac destdir="build/tmp" encoding="${source.encoding}" source="1.8" target="1.8" classpath="JavaSE.jar"> <src path="${src.dir}:stubs/desktop"/> </javac> <copy file="../cn1/Themes/iOS7Theme.res" todir="build/tmp" /> <jar jarfile="kitchesink-desktop.jar"> <manifest> <5> <attribute name="Main-Class" value="com.codename1.demos.kitchen.KitchenSinkStub"/> </manifest> <fileset dir="../cn1/Ports/JavaSE/build/classes" excludes="*.skin" /> <fileset dir="build/tmp" /> <fileset dir="src" excludes="*.java" /> </jar> </target> build.xml
  • 17. <target name="desktop" depends="init"> <delete dir="build/tmp" /> <mkdir dir="build/tmp" /> <javac destdir="build/tmp" encoding="${source.encoding}" source="1.8" target="1.8" classpath="JavaSE.jar"> <src path="${src.dir}:stubs/desktop"/> </javac> <copy file="../cn1/Themes/iOS7Theme.res" todir="build/tmp" /> <jar jarfile="kitchesink-desktop.jar"> <manifest> <5> <attribute name="Main-Class" value="com.codename1.demos.kitchen.KitchenSinkStub"/> </manifest> <fileset dir="../cn1/Ports/JavaSE/build/classes" excludes="*.skin" /> <fileset dir="build/tmp" /> <fileset dir="src" excludes="*.java" /> </jar> </target> build.xml
  • 18. <target name="desktop" depends="init"> <delete dir="build/tmp" /> <mkdir dir="build/tmp" /> <javac destdir="build/tmp" encoding="${source.encoding}" source="1.8" target="1.8" classpath="JavaSE.jar"> <src path="${src.dir}:stubs/desktop"/> </javac> <copy file="../cn1/Themes/iOS7Theme.res" todir="build/tmp" /> <jar jarfile="kitchesink-desktop.jar"> <manifest> <5> <attribute name="Main-Class" value="com.codename1.demos.kitchen.KitchenSinkStub"/> </manifest> <fileset dir="../cn1/Ports/JavaSE/build/classes" excludes="*.skin" /> <fileset dir="build/tmp" /> <fileset dir="src" excludes="*.java" /> </jar> </target> build.xml
  • 19. <target name="desktop" depends="init"> <delete dir="build/tmp" /> <mkdir dir="build/tmp" /> <javac destdir="build/tmp" encoding="${source.encoding}" source="1.8" target="1.8" classpath="JavaSE.jar"> <src path="${src.dir}:stubs/desktop"/> </javac> <copy file="../cn1/Themes/iOS7Theme.res" todir="build/tmp" /> <jar jarfile="kitchesink-desktop.jar"> <manifest> <5> <attribute name="Main-Class" value="com.codename1.demos.kitchen.KitchenSinkStub"/> </manifest> <fileset dir="../cn1/Ports/JavaSE/build/classes" excludes="*.skin" /> <fileset dir="build/tmp" /> <fileset dir="src" excludes="*.java" /> </jar> </target> build.xml
  • 20. <target name="desktop" depends="init"> <delete dir="build/tmp" /> <mkdir dir="build/tmp" /> <javac destdir="build/tmp" encoding="${source.encoding}" source="1.8" target="1.8" classpath="JavaSE.jar"> <src path="${src.dir}:stubs/desktop"/> </javac> <copy file="../cn1/Themes/iOS7Theme.res" todir="build/tmp" /> <jar jarfile="kitchesink-desktop.jar"> <manifest> <5> <attribute name="Main-Class" value="com.codename1.demos.kitchen.KitchenSinkStub"/> </manifest> <fileset dir="../cn1/Ports/JavaSE/build/classes" excludes="*.skin" /> <fileset dir="build/tmp" /> <fileset dir="src" excludes="*.java" /> </jar> </target> build.xml
  • 21. <target name="desktop" depends="init"> <delete dir="build/tmp" /> <mkdir dir="build/tmp" /> <javac destdir="build/tmp" encoding="${source.encoding}" source="1.8" target="1.8" classpath="JavaSE.jar"> <src path="${src.dir}:stubs/desktop"/> </javac> <copy file="../cn1/Themes/iOS7Theme.res" todir="build/tmp" /> <jar jarfile="kitchesink-desktop.jar"> <manifest> <5> <attribute name="Main-Class" value="com.codename1.demos.kitchen.KitchenSinkStub"/> </manifest> <fileset dir="../cn1/Ports/JavaSE/build/classes" excludes="*.skin" /> <fileset dir="build/tmp" /> <fileset dir="src" excludes="*.java" /> </jar> </target> build.xml