amoebax.cpp
来自「Source code (C++) of the Amoebax game fo」· C++ 代码 · 共 81 行
CPP
81 行
#include <eikenv.h>
#include <eikapp.h>
#include <eikappui.h>
#include <stdio.h>
#include <eikapp.h>
#include <e32base.h>
#include <sdlapp.h>
class CAmoebaxApp: public CSDLApp {
public:
CAmoebaxApp();
~CAmoebaxApp();
/**
* Returns the resource id to be used to declare the views supported by this UIQ3 app
* @return TInt, resource id
*/
TInt ViewResourceId();
TUid AppDllUid() const;
};
CApaApplication* NewApplication() {
// Return pointer to newly created CQMApp
return new CAmoebaxApp;
}
#include <eikstart.h>
// E32Main() contains the program's start up code, the entry point for an EXE.
GLDEF_C TInt E32Main() {
return EikStart::RunApplication(NewApplication);
}
void log(const char* aString)
{
FILE* f = fopen("d:\\Amoebax.log","a+b");
if(f != NULL)
{
fprintf(f,aString);
fprintf(f, "\n");
fclose(f);
}
}
CAmoebaxApp::CAmoebaxApp() {
}
CAmoebaxApp::~CAmoebaxApp() {
}
#include <Amoebax.rsg>
/**
* Returns the resource id to be used to declare the views supported by this UIQ3 app
* @return TInt, resource id
*/
TInt CAmoebaxApp::ViewResourceId() {
return R_SDL_VIEW_UI_CONFIGURATIONS;
}
char symbianDataDrive()
{
char drive = CEikonEnv::Static()->EikAppUi()->Application()->BitmapStoreName()[0];
return drive;
}
/**
* Responsible for returning the unique UID of this application
* @return unique UID for this application in a TUid
**/
TUid CAmoebaxApp::AppDllUid() const {
return TUid::Uid(0xA0003399);
}
/////////////////////////////////////////////////////////////////////////////////////////////////
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?