Skip to content

Instantly share code, notes, and snippets.

View YutaWatanabe's full-sized avatar

Yuta Watanabe YutaWatanabe

  • Civitas, Inc.
  • Tokyo, Japan
View GitHub Profile
@YutaWatanabe
YutaWatanabe / button.html
Created August 31, 2014 10:29
Button sample
<button id="eventButton">Click</button>
@YutaWatanabe
YutaWatanabe / linqtoxmlmonotouchdialog.cs
Created September 3, 2014 13:51
LINQ to XML with Monotouch.Dialog
public override bool FinishedLaunching (UIApplication app, NSDictionary options)
{
window = new UIWindow (UIScreen.MainScreen.Bounds);
//XMLファイルを読み込み
var doc = XDocument.Load ("SessionData.xml");
// LINQ to XML & Monotouch.Dialog
@YutaWatanabe
YutaWatanabe / jmlist.html
Created September 8, 2014 06:40
jQuery Mobile ListView Sample
<ul data-role="listview" data-inset="true" data-filter-placeholder="Search products..." data-filter="true">
<li><a href="#">Windows</a></li>
<li><a href="#">Office</a></li>
<li><a href="#">XBOX</a></li>
<li><a href="#">Windows Phone</a></li>
<li><a href="#">Visual Studio</a></li>
<li><a href="#">Microsoft Azure</a></li>
</ul>
@YutaWatanabe
YutaWatanabe / server.js
Created September 14, 2014 01:16
Getting started with Express
var express = require('express');
var app = express();
app.get('/', function(req, res){
res.send('Hello World');
}).listen(3000);
@YutaWatanabe
YutaWatanabe / server.js
Created September 14, 2014 01:41
Getting started with jade & express
var express = require('express');
var app = express();
app.set('view engine', 'jade');
app.set('views', './views')
app.get('/', function(req, res){
//res.send('Hello World');
res.render('index', { title: 'Express', message: 'Rendered by Jade'});
}).listen(3000);
@YutaWatanabe
YutaWatanabe / index.jade
Created September 14, 2014 01:42
jade sample
html
head
title!= title
body
h1!= message
@YutaWatanabe
YutaWatanabe / forms.cs
Created September 28, 2014 02:07
xamarin.forms sample
return new TabbedPage {
Children = {
new ContentPage {
Title = "Home",
Content = new StackLayout {
VerticalOptions = LayoutOptions.CenterAndExpand,
HorizontalOptions = LayoutOptions.CenterAndExpand,
Children = {
new Label {
Text = "Xamarin.Forms",
@YutaWatanabe
YutaWatanabe / audio.js
Created October 12, 2014 08:32
play audio in phonegap
document.getElementById("playBtn")
.addEventListener("click", function(){
var media = new Media(
"/android_asset/www/sample.mp3",
function(){
console.log("success");
},
function(err){
console.log("fail");
}
@YutaWatanabe
YutaWatanabe / enemy-part.cs
Created October 15, 2014 07:17
Part of Enemy.cs in 2D Platformer ( Unity )
// Increase the score by 100 points
score.score += 100;
@YutaWatanabe
YutaWatanabe / condition.cs
Last active August 29, 2015 14:07
Condition statement in Unity debugging
this.score.score > 300