This file contains hidden or 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
| <?php | |
| class Foo { | |
| public function bar() { | |
| return "bar"; | |
| } | |
| public static function baz() { |
This file contains hidden or 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 Animal() { | |
| /* properties */ | |
| this.isWild = true; | |
| this.name = ''; | |
| this.sound = ''; | |
| this.height = 0; // cm | |
| this.weight = 0; // kg | |
| this.speed = 0; // km/h | |
| this.age = 0; // years old |
This file contains hidden or 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
Show hidden characters
| { | |
| "theme": "Soda Dark 3.sublime-theme", | |
| "color_scheme": "Packages/Color Scheme - Default/Twilight.tmTheme", | |
| // "color_scheme": "Packages/Color Scheme - Default/Solarized (Light).tmTheme", | |
| // "theme": "Spacegray.sublime-theme", | |
| // "color_scheme": "Packages/Theme - Spacegray/base16-ocean.dark.tmTheme", | |
This file contains hidden or 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
| main = putStrLn "Hello, World!" |
This file contains hidden or 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
| Object.prototype.getName = function() { | |
| var funcNameRegex = /function (.{1,})\(/; | |
| var results = (funcNameRegex).exec((this).constructor.toString()); | |
| return (results && results.length > 1) ? results[1] : ""; | |
| }; |
This file contains hidden or 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
| <script src="/scripts/require.js"></script> | |
| <script src="/scripts/require.config.js"></script> | |
| <script> | |
| require(['slider'], function ($) { | |
| console.log($); // jquery with slider | |
| //console.log($('.slide').nivoSlider({})); | |
| }); | |
| </script> |
This file contains hidden or 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
| // | |
| // DetailsController.m | |
| // iOsNative | |
| #import "DetailsController.h" | |
| #import "CustomDetailsCell.h" | |
| #import "JsonReader.h" | |
| #import "PList.h" | |
| @implementation DetailsController |
This file contains hidden or 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
| /* | |
| Common vector operations | |
| Author: Tudor Nita | cgrats.com | |
| Version: 0.51 | |
| */ | |
| function Vec2(x_,y_) | |
| { | |
| this.x = x_; | |
| this.y = y_; |
This file contains hidden or 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
| $('.fullscreenbutton').on('click', function () { | |
| function toggleFullScreen() { | |
| if (!document.fullscreenElement && // alternative standard method | |
| !document.mozFullScreenElement && !document.webkitFullscreenElement) { // current working methods | |
| if (document.documentElement.requestFullscreen) { | |
| document.documentElement.requestFullscreen(); | |
| } else if (document.documentElement.mozRequestFullScreen) { | |
| document.documentElement.mozRequestFullScreen(); | |
| } else if (document.documentElement.webkitRequestFullscreen) { |
This file contains hidden or 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
| var ev = '', | |
| out = []; | |
| for (ev in window) { | |
| if (/^on/.test(ev)) { | |
| out[out.length] = ev; | |
| } | |
| } | |
| console.log(out.join(', ')); |