Skip to content

Instantly share code, notes, and snippets.

View Colmea's full-sized avatar
🏠
Working from home

Arthur Schwaiger Colmea

🏠
Working from home
View GitHub Profile
@Colmea
Colmea / GUILayout.js
Created January 18, 2016 09:02
TypeError: _super.call is not a function(…)
// Generated JS file
var __extends = (this && this.__extends) || function (d, b) {
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p];
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
define(["require", "exports", './GUIElement'], function (require, exports, GUIElement) {
var GUILayout = (function (_super) {
__extends(GUILayout, _super);
var __extends = (this && this.__extends) || function (d, b) {
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p];
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
define(["require", "exports", './GUIElement'], function (require, exports, GUIElement) {
var GUILayout = (function (_super) {
__extends(GUILayout, _super);
/**
* Constructor
@Colmea
Colmea / GUILayout.ts
Created January 16, 2016 17:23
TypeError: _super.call is not a function(…)
import GUIElement = require('./GUIElement');
class GUILayout extends GUIElement implements IGUILayout {
// Public members
public panels: Array<GUIPanel> = new Array<GUIPanel>();
/**
* Constructor
* @param name layout name
* @param app App instance
@Colmea
Colmea / Module.php
Created March 10, 2015 12:55
Custom View Helper ZF2
use MyModule\View\Helper\MyViewHelper;
class Module
{
[...]
public function getViewHelperConfig()
{
return array(
'factories' => array(
if ($request->isPost())
{
$data = array_merge($request->getPost()->toArray(), $this->getRequest()->getFiles()->toArray());
$form->setData($data);
[...]
OUTPUT:
array (size=5)
array (size=2)
'filename' =>
array (size=1)
'isEmpty' => string 'Une valeur est requise et ne peut être vide' (length=44)
'file' =>
array (size=1)
'fileUploadFileErrorNoFile' => string 'Le fichier n'a pas été envoyé' (length=32)
requirejs.config({
baseUrl: basePath + '/plugins/designer/scripts/lib',
paths: {
designer: '../app',
object: '../app/object',
samples: '../app/samples',
constraints: '../app/constraints',
public: '../../../..',
data:image/jpeg;base64,/9j/4AAQSkZJRgABAQAAAQABAAD/2wBDAAMCAgICAgMCAgIDAwMDBAYEBAQEBAgGBgUGCQgKCgkICQkKDA8MCgsOCwkJDRENDg8QEBEQCgwSExIQEw8QEBD/2wBDAQMDAwQDBAgEBAgQCwkLEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBD/wAARCAGQANkDAREAAhEBAxEB/8QAHwAAAQUBAQEBAQEAAAAAAAAAAAECAwQFBgcICQoL/8QAtRAAAgEDAwIEAwUFBAQAAAF9AQIDAAQRBRIhMUEGE1FhByJxFDKBkaEII0KxwRVS0fAkM2JyggkKFhcYGRolJicoKSo0NTY3ODk6Q0RFRkdISUpTVFVWV1hZWmNkZWZnaGlqc3R1dnd4eXqDhIWGh4iJipKTlJWWl5iZmqKjpKWmp6ipqrKztLW2t7i5usLDxMXGx8jJytLT1NXW19jZ2uHi4+Tl5ufo6erx8vP09fb3+Pn6/8QAHwEAAwEBAQEBAQEBAQAAAAAAAAECAwQFBgcICQoL/8QAtREAAgECBAQDBAcFBAQAAQJ3AAECAxEEBSExBhJBUQdhcRMiMoEIFEKRobHBCSMzUvAVYnLRChYkNOEl8RcYGRomJygpKjU2Nzg5OkNERUZHSElKU1RVVldYWVpjZGVmZ2hpanN0dXZ3eHl6goOEhYaHiImKkpOUlZaXmJmaoqOkpaanqKmqsrO0tba3uLm6wsPExcbHyMnK0tPU1dbX2Nna4uPk5ebn6Onq8vP09fb3+Pn6/9oADAMBAAIRAxEAPwD9S/7PsP8Anxt/+/S/4UAH9n2H/Pjb/wDfpf8ACgA/s+w/58bf/v0v+FAB/Z9h/wA+Nv8A9+l/woAP7PsP+fG3/wC/S/4UAH9n2H/Pjb/9+l/woAP7PsP+fG3/AO/S/wCFAB/Z9h/z42//AH6X/CgA/s+w/wCfG3/79L/hQAf2f