This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class='overlay' id='auth-overlay'> | |
<div class="container" id="auth-super"> | |
<div class="row"> | |
<div class="col-sm-6" style="background: #afa6a6;border-radius: 10px;"> | |
<div id="auth-dialog"> | |
<div id="title-section"> | |
<div class="row"> | |
<div class="col-sm-8 col-sm-offset-3"><span><h4>PubNub WebRTC App with Parse</h4></span></div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public void successCallback(String channel, Object message) { | |
// TODO Auto-generated method stub | |
super.successCallback(channel, message); | |
Log.i("Subscribe","SUCCESS"+message.getClass()+" "+message.toString()); | |
try { | |
Globalvars.isSubscribed = true; | |
Log.i("Subscribe","SUCCESS sending message"+message.toString()); | |
Intent intent = new Intent(MY_ACTION); | |
intent.putExtra("message", message.toString()); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Define Backbone Stats model | |
app.Stat = Backbone.Model.extend({ | |
defaults: { | |
stats: [[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0]] | |
}, | |
localStorage: new Backbone.LocalStorage("pcm-stat") | |
}); | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
TaskPanel.prototype.addTask = function addTask(taskObj) { | |
var that = this; | |
var pos = this.taskSurfaces.length; | |
var tempTrans = new TransitionableTransform(); | |
var sizeTrans = new Transitionable([5, 5]); | |
var opacTrans = new Transitionable(0); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function fetch (place, coordinates, i, aggregate) { | |
async.parallel([ | |
function(callback) { | |
request | |
.get('https://maps.googleapis.com/maps/api/timezone/json') | |
.query('location='+coordinates[1]+','+coordinates[0]) | |
.query({timestamp: Math.floor(new Date().getTime()/1000)}) | |
.query({key: gApiToken}) | |
.end(function(err, res){ | |
if(err) { console.log(err); callback(true); return; } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def distanceMeasurement(): | |
prev_distance = 0 | |
while 1: | |
ultrasonicSensor_init() | |
time.sleep(2) | |
GPIO.output(TRIG, True) | |
time.sleep(0.00001) | |
GPIO.output(TRIG, False) | |
#Starts the timer | |
while GPIO.input(ECHO)==0: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static List<decimal> arrUSDEUR = new List<decimal>();// globally declaring list for USDEUR | |
public static List<decimal> arrUSDAUD = new List<decimal>();// globally declaring list for USDAUD | |
public static List<decimal> arrUSDCNY = new List<decimal>();// globally declaring list for USDCNY | |
public static List<decimal> arrUSDINR = new List<decimal>();// globally declaring list for USDINR | |
public static Dictionary<string, List<decimal>> ArrayDictMap = new Dictionary<string, List<decimal>>() | |
{ | |
{ "USDEUR", arrUSDEUR }, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
handleComment = function(obj,commentObj){ | |
var comment = commentObj.commentsAndMeta.comment[0]; | |
var foundComment = false; | |
var i = 0; | |
while(i < obj.links.length){ | |
if((obj.links[i].type == 1) && (obj.links[i].target.data.comment_id == comment.comment_id) ){ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/***************************************************************************/ | |
/*PubNub C-Core Initialization*/ | |
pubnub_t *l_receive = pubnub_alloc(); | |
if (NULL == l_receive) | |
{ | |
printf("Failed to allocate Pubnub context!\n"); | |
return (void *)-1; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Function to close the dashdb connection | |
def dbclose(self): | |
try: | |
retrn = ibm_db.close(self.connection) | |
return retrn | |
except Exception as dbcloseerror: | |
logging.error("dbclose Exception %s"%(dbcloseerror)) | |
return False |
OlderNewer