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
#include "config.h" | |
#include <iostream> | |
Config::Config(int data):_pimpl(new Impl(data)){ | |
} | |
Config::Impl::Impl(int data): _data(data){ |
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
#include "config.h" | |
#include <iostream> | |
Config::Config():_pimpl(new Impl), _refCount(1){ | |
} | |
Config::Config(const Config& config): _pimpl(config._pimpl), _refCount(1){ | |
config.ref(); | |
} |
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
var core = { | |
clone: function(o){ | |
var c; | |
if(typeof o != 'object'){ | |
c = o; | |
}else{ | |
c = {}; | |
for(i in o){ | |
c[i] = this.clone(o[i]); | |
} |
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
U2FsYSBCb2thY2hvZGEgSGFyYW1pIFN1b3JlciBCYWNoY2hhLiBHYXJlIGVrIExhdGhpIE1hcmJl | |
IEdhbmR1IGVraG9uIHRvciBHaHVtIFBhY2hjaGhlID8gYm9sIG5hIGtha2UgYWRkcmVzcyBrb3Jl | |
IExpa2hsaSA/Pw== |
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
var FMRuntime = { | |
/** | |
* Changes Directory | |
* \internal Just Calls _cd() and _ls() serialy. | |
* \return void | |
*/ | |
cd : function(){ | |
}, | |
/** |
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
void ArthurStyle::drawPrimitive(PrimitiveElement element, const QStyleOption *option, QPainter *painter, const QWidget *widget) const{ | |
Q_ASSERT(option); | |
switch (element) { | |
case PE_FrameFocusRect: | |
break; | |
case PE_IndicatorRadioButton: | |
if (const QStyleOptionButton *button = qstyleoption_cast<const QStyleOptionButton *>(option)) { | |
bool hover = (button->state & State_Enabled) && (button->state & State_MouseOver); |
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
#ifndef PHPCONSTRUCTIDENTITY_H | |
#define PHPCONSTRUCTIDENTITY_H | |
#include <QStringList> | |
#include <map> | |
#include <algorithm> | |
class PHPConstructIdentity{ | |
public: | |
PHPConstructIdentity(); |
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
class MarkSheetTableModel : public QAbstractTableModel{ | |
public: | |
MarkSheetTableModel(QObject* parent=0); | |
~MarkSheetTableModel(); | |
private: | |
QList<QString> subjects;//Headers Come from Here | |
QHash<QString, QList<double>* > students;//each student and their corresponding marks make a row | |
public: | |
QList<double>& addStudent(const QString& stdName); | |
QList<double>& student(const QString& stdName); |
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
<?php | |
class UserManagerConfig extends Config{ | |
public host = ""; | |
public user = ""; | |
public pass = ""; | |
//..... | |
public database = ""; | |
} | |
/* | |
when you are in OOPS avoid using associative arrays use Objects Instead |
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
#ifdef HAVE_CONFIG_H | |
#include <config.h> | |
#endif | |
#include <iostream> | |
#include <cstdlib> | |
#include "myapp.h" | |
int main(int argc, char *argv[]){ | |
MyApp app; |