Skip to content

Commit

Permalink
Merge branch 'develop' into stable
Browse files Browse the repository at this point in the history
  • Loading branch information
manuel-mauky committed Aug 14, 2014
2 parents 2e19118 + 25690f7 commit 592fae9
Show file tree
Hide file tree
Showing 190 changed files with 6,787 additions and 4,864 deletions.
16 changes: 16 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
language: java

jdk:
- oraclejdk8

before_install:
- export DISPLAY=:99.0
- sh -e /etc/init.d/xvfb start

env:
global:
- secure: f4P8Bw0z427Domw/AhnOKRFOYTXkUnPr1QO/M033FferhDivssUgcX8Rmutxy3AwKV1uYoSyJDW8Hzaj6bbJ7wbh9Yetbfo6IP8vw0gfJEvndSjpmu/x9R/0Os3jbSy4Irq5+gZZzN+ba7fySMNkBD2NoAHb/xp8RskJXPOgqas=
- secure: Bm0zIwBo4saIBlfr9YDvNqd8UN50FeT2hZyum3RFDmJqaXiUqwxw7sCz/lRjUwTfQrvGJXQ1I8le7zE4OVQdvpn4/LwwTJIjLY2jZNjzs4mZhkHzsM5IcGcL3lukR6soVYrGloQwmw63Okw2kZxces+1fveisPIKDlVaU1RTtMQ=

after_success:
- "[[ $TRAVIS_BRANCH == \"develop\" ]] && { python addServer.py; mvn clean deploy -DskipTests=true --settings ~/.m2/mySettings.xml; };"
9 changes: 9 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,12 @@ __MVVM__ is the enhanced version of the [Presentation Model](http://martinfowler
</dependency>
```

### Links

[javadoc mvvmfx core](http://sialcasa.github.io/mvvmFX/javadoc/0.2.0/mvvmfx/)

[javadoc mvvmfx-cdi](http://sialcasa.github.io/mvvmFX/javadoc/0.2.0/mvvmfx-cdi/)

[javadoc mvvmfx-guice](http://sialcasa.github.io/mvvmFX/javadoc/0.2.0/mvvmfx-guice/)

[![Build Status](https://travis-ci.org/sialcasa/mvvmFX.svg?branch=develop)](https://travis-ci.org/sialcasa/mvvmFX)
57 changes: 57 additions & 0 deletions addServer.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
#!/usr/bin/env python

# This script file is used for travis-ci snapshot deployment.

# This script creates a maven settings file 'mySettings.xml'.
# If there is an existing settings.xml, it is used as base for the new settings file.
# After that it adds the server configuration for the sonatype maven repository
# The username and password are taken from environment variables named SONATYPE_USERNAME and SONATYPE_PASSWORD

# This script is taken from: https://gist.github.com/neothemachine/4060735



import sys
import os
import os.path
import xml.dom.minidom

if os.environ["TRAVIS_SECURE_ENV_VARS"] == "false":
print "no secure env vars available, skipping deployment"
sys.exit()

homedir = os.path.expanduser("~")

m2 = xml.dom.minidom.parse(homedir + '/.m2/settings.xml')
settings = m2.getElementsByTagName("settings")[0]

serversNodes = settings.getElementsByTagName("servers")
if not serversNodes:
serversNode = m2.createElement("servers")
settings.appendChild(serversNode)
else:
serversNode = serversNodes[0]

sonatypeServerNode = m2.createElement("server")
sonatypeServerId = m2.createElement("id")
sonatypeServerUser = m2.createElement("username")
sonatypeServerPass = m2.createElement("password")

idNode = m2.createTextNode("sonatype-nexus-snapshots")
userNode = m2.createTextNode(os.environ["SONATYPE_USERNAME"])
passNode = m2.createTextNode(os.environ["SONATYPE_PASSWORD"])

sonatypeServerId.appendChild(idNode)
sonatypeServerUser.appendChild(userNode)
sonatypeServerPass.appendChild(passNode)

sonatypeServerNode.appendChild(sonatypeServerId)
sonatypeServerNode.appendChild(sonatypeServerUser)
sonatypeServerNode.appendChild(sonatypeServerPass)

serversNode.appendChild(sonatypeServerNode)

m2Str = m2.toxml()
f = open(homedir + '/.m2/mySettings.xml', 'w')
f.write(m2Str)
f.close()
3 changes: 3 additions & 0 deletions examples/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,6 @@ To run this example you need either mvvmfx-cdi-starter or mvvmfx-guice-starter.
as dependency injection framework.
- **mvvmfx-guice-starter**: contains the startup code to run the mvvmfx-complex-example with Guice
as dependency injection framework.
- **mvvmfx-fx-root-example**: contains a small custom control that uses the fx:root element together with mvvmfx.
- **mvvmfx-helloworld-example**: A simple hello world view. This example is used in the [Getting Started/Step-by-Step tutorial](/../../wiki/Getting-Started-HelloWorld-%28deutsch%29).
- **mvvmfx-helloworld-without-fxml**: A hello world example that shows hot to use MvvmFX with a view implemented in pure Java and not with FXML.
81 changes: 42 additions & 39 deletions examples/mvvmfx-cdi-starter/pom.xml
Original file line number Diff line number Diff line change
@@ -1,67 +1,70 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>de.saxsys</groupId>
<artifactId>mvvmfx-cdi-example</artifactId>
<version>${mvvmfx.version}</version>

<name>mvvmFX CDI Example</name>

<description>
This example shows the usage of the mvvmFX framework with CDI Dependency Injection.
This example shows the usage of the mvvmFX framework with CDI Dependency Injection.
</description>

<parent>
<groupId>de.saxsys</groupId>
<artifactId>mvvmFX-examples</artifactId>
<version>0.3.0</version>
</parent>

<properties>
<mvvmfx.version>0.2.0</mvvmfx.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<maven.compiler.source>1.7</maven.compiler.source>
<maven.compiler.target>1.7</maven.compiler.target>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
</properties>


<dependencies>
<dependency>
<groupId>javax.inject</groupId>
<artifactId>javax.inject</artifactId>
<version>1</version>
</dependency>
<dependency>
<groupId>javax.enterprise</groupId>
<artifactId>cdi-api</artifactId>
<version>1.1</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-simple</artifactId>
<version>1.7.6</version>
</dependency>
<dependency>
<groupId>javax.inject</groupId>
<artifactId>javax.inject</artifactId>
<version>1</version>
</dependency>
<dependency>
<groupId>javax.enterprise</groupId>
<artifactId>cdi-api</artifactId>
<version>1.1</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-simple</artifactId>
<version>1.7.6</version>
</dependency>

<dependency>
<groupId>de.saxsys</groupId>
<artifactId>mvvmFX</artifactId>
<version>${mvvmfx.version}</version>
<version>${project.parent.version}</version>
</dependency>
<dependency>
<groupId>de.saxsys</groupId>
<artifactId>mvvmFX-cdi</artifactId>
<version>${project.parent.version}</version>
</dependency>
<dependency>
<groupId>org.jboss.weld.se</groupId>
<artifactId>weld-se</artifactId>
<version>2.1.0.Final</version>
</dependency>
<dependency>
<groupId>de.saxsys</groupId>
<artifactId>mvvmfx-complex</artifactId>
<version>${project.parent.version}</version>
</dependency>
<dependency>
<groupId>de.saxsys</groupId>
<artifactId>mvvmFX-cdi</artifactId>
<version>${mvvmfx.version}</version>
</dependency>
<dependency>
<groupId>org.jboss.weld.se</groupId>
<artifactId>weld-se</artifactId>
<version>2.1.0.Final</version>
</dependency>
<dependency>
<groupId>de.saxsys</groupId>
<artifactId>mvvmfx-complex</artifactId>
<version>${mvvmfx.version}</version>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.11</version>
<scope>test</scope>
</dependency>
</dependencies>
</dependencies>

</project>
Original file line number Diff line number Diff line change
@@ -1,40 +1,35 @@
package de.saxsys.jfx;

import de.saxsys.jfx.exampleapplication.view.maincontainer.MainContainerView;
import de.saxsys.jfx.exampleapplication.viewmodel.maincontainer.MainContainerViewModel;
import de.saxsys.jfx.mvvm.cdi.MvvmfxCdiApplication;
import de.saxsys.jfx.mvvm.viewloader.ViewLoader;
import de.saxsys.jfx.mvvm.viewloader.ViewTuple;
import javafx.scene.Parent;
import javafx.scene.Scene;
import javafx.stage.Stage;

import javax.inject.Inject;
import de.saxsys.jfx.exampleapplication.view.maincontainer.MainContainerView;
import de.saxsys.jfx.exampleapplication.viewmodel.maincontainer.MainContainerViewModel;
import de.saxsys.mvvmfx.cdi.MvvmfxCdiApplication;
import de.saxsys.mvvmfx.FluentViewLoader;
import de.saxsys.mvvmfx.ViewTuple;

/**
* The application entry point.
*
* @author manuel.mauky
*/
public class Starter extends MvvmfxCdiApplication {

public static void main(String... args) {
launch(args);
}

@Inject
private ViewLoader viewLoader;

@Override
public void start(Stage stage) {
ViewTuple<MainContainerView, MainContainerViewModel> tuple =
viewLoader
.loadViewTuple(MainContainerView.class);

Parent view = tuple.getView();

final Scene scene = new Scene(view);
stage.setScene(scene);
stage.show();
}

public static void main(String... args) {
launch(args);
}

@Override
public void start(Stage stage) {
ViewTuple<MainContainerView, MainContainerViewModel> tuple =
FluentViewLoader.fxmlView(MainContainerView.class).load();

Parent view = tuple.getView();

final Scene scene = new Scene(view);
stage.setScene(scene);
stage.show();
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,4 @@
<beans xmlns="http://xmlns.jcp.org/xml/ns/javaee">



</beans>
29 changes: 17 additions & 12 deletions examples/mvvmfx-complex-example/pom.xml
Original file line number Diff line number Diff line change
@@ -1,15 +1,18 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>de.saxsys</groupId>
<artifactId>mvvmfx-complex</artifactId>
<version>${mvvmfx.version}</version>
<name>Complex Example</name>

<parent>
<groupId>de.saxsys</groupId>
<artifactId>mvvmFX-examples</artifactId>
<version>0.3.0</version>
</parent>
<properties>
<mvvmfx.version>0.2.0</mvvmfx.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<maven.compiler.source>1.7</maven.compiler.source>
<maven.compiler.target>1.7</maven.compiler.target>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
</properties>

<repositories>
Expand All @@ -24,11 +27,11 @@
</repositories>

<dependencies>
<dependency>
<groupId>javax.inject</groupId>
<artifactId>javax.inject</artifactId>
<version>1</version>
</dependency>
<dependency>
<groupId>javax.inject</groupId>
<artifactId>javax.inject</artifactId>
<version>1</version>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
Expand All @@ -43,7 +46,7 @@
<dependency>
<groupId>de.saxsys</groupId>
<artifactId>mvvmFX</artifactId>
<version>${mvvmfx.version}</version>
<version>${project.parent.version}</version>
</dependency>
<dependency>
<groupId>com.google.guava</groupId>
Expand All @@ -69,7 +72,9 @@
</descriptorRefs>
</configuration>
</plugin>

</plugins>

</build>

</project>
Loading

0 comments on commit 592fae9

Please sign in to comment.