mirror of
https://github.com/libretro/Play-.git
synced 2025-02-13 21:19:46 +00:00
git-svn-id: http://svn.purei.org/purei/trunk@154 b36208d7-6611-0410-8bec-b1987f11c4a2
This commit is contained in:
parent
e7a02f3461
commit
cd4f5907bf
@ -41,7 +41,7 @@
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories="$(FrameworkRoot)\include"
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS"
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_CRT_SECURE_NO_WARNINGS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
@ -61,6 +61,7 @@
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="comctl32.lib"
|
||||
LinkIncremental="2"
|
||||
GenerateDebugInformation="true"
|
||||
SubSystem="2"
|
||||
@ -117,7 +118,7 @@
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalIncludeDirectories="$(FrameworkRoot)\include"
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS"
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_CRT_SECURE_NO_WARNINGS"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
@ -135,6 +136,7 @@
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="comctl32.lib"
|
||||
LinkIncremental="1"
|
||||
GenerateDebugInformation="true"
|
||||
SubSystem="2"
|
||||
@ -180,6 +182,42 @@
|
||||
RelativePath="..\..\Source\ELF.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Source\win32ui\ELFHeaderView.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Source\win32ui\ELFProgramView.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Source\win32ui\ELFSectionView.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Source\win32ui\ELFSymbolView.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Source\win32ui\ELFView.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Source\ElfViewFrame.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Source\win32ui\MemoryView.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Source\win32ui\MemoryViewPtr.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Source\win32ui\OptionWnd.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Source\WinMain.cpp"
|
||||
>
|
||||
@ -194,6 +232,42 @@
|
||||
RelativePath="..\..\Source\ELF.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Source\win32ui\ELFHeaderView.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Source\win32ui\ELFProgramView.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Source\win32ui\ELFSectionView.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Source\win32ui\ELFSymbolView.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Source\win32ui\ELFView.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Source\ElfViewFrame.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Source\win32ui\MemoryView.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Source\win32ui\MemoryViewPtr.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Source\win32ui\OptionWnd.h"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Resource Files"
|
||||
|
36
tools/ElfView/Source/ElfViewFrame.cpp
Normal file
36
tools/ElfView/Source/ElfViewFrame.cpp
Normal file
@ -0,0 +1,36 @@
|
||||
#include "ElfViewFrame.h"
|
||||
#include "win32/Rect.h"
|
||||
|
||||
using namespace Framework;
|
||||
|
||||
#define CLSNAME _T("ElfViewFrame")
|
||||
|
||||
CElfViewFrame::CElfViewFrame()
|
||||
{
|
||||
if(!DoesWindowClassExist(CLSNAME))
|
||||
{
|
||||
WNDCLASSEX wc;
|
||||
memset(&wc, 0, sizeof(WNDCLASSEX));
|
||||
wc.cbSize = sizeof(WNDCLASSEX);
|
||||
wc.hCursor = LoadCursor(NULL, IDC_ARROW);
|
||||
wc.hbrBackground = (HBRUSH)GetStockObject(GRAY_BRUSH);
|
||||
wc.hInstance = GetModuleHandle(NULL);
|
||||
wc.lpszClassName = CLSNAME;
|
||||
wc.lpfnWndProc = CWindow::WndProc;
|
||||
RegisterClassEx(&wc);
|
||||
}
|
||||
|
||||
Create(NULL, CLSNAME, _T("Elf Viewer"), WS_OVERLAPPEDWINDOW | WS_CLIPCHILDREN,
|
||||
Win32::CRect(0, 0, 640, 480), NULL, NULL);
|
||||
SetClassPtr();
|
||||
|
||||
// SetMenu(LoadMenu(GetModuleHandle(NULL), MAKEINTRESOURCE(IDR_DEBUGGER)));
|
||||
|
||||
CreateClient(NULL);
|
||||
}
|
||||
|
||||
CElfViewFrame::~CElfViewFrame()
|
||||
{
|
||||
|
||||
}
|
||||
|
16
tools/ElfView/Source/ElfViewFrame.h
Normal file
16
tools/ElfView/Source/ElfViewFrame.h
Normal file
@ -0,0 +1,16 @@
|
||||
#ifndef _ELFVIEWFRAME_H_
|
||||
#define _ELFVIEWFRAME_H_
|
||||
|
||||
#include "win32/MDIFrame.h"
|
||||
|
||||
class CElfViewFrame : public Framework::Win32::CMDIFrame
|
||||
{
|
||||
public:
|
||||
CElfViewFrame();
|
||||
virtual ~CElfViewFrame();
|
||||
|
||||
private:
|
||||
|
||||
};
|
||||
|
||||
#endif
|
@ -1,6 +1,21 @@
|
||||
#include <windows.h>
|
||||
//#include "..\Purei\Source\ELF.h"
|
||||
//#include "..\Purei\Source\win32ui\ELFView.h"
|
||||
//#include "StdStream.h"
|
||||
#include "ElfViewFrame.h"
|
||||
|
||||
using namespace Framework;
|
||||
|
||||
int WINAPI WinMain(HINSTANCE instance, HINSTANCE prevInstance, LPSTR params, int showCmd)
|
||||
{
|
||||
CElfViewFrame elfViewFrame;
|
||||
elfViewFrame.Center();
|
||||
elfViewFrame.Show(SW_SHOW);
|
||||
// CStdStream stream("D:\\rar\\Purei\\psf2.irx", "rb");
|
||||
// CELF elf(&stream);
|
||||
// CELFView elfView(NULL);
|
||||
// elfView.SetELF(&elf);
|
||||
// elfView.Show(SW_SHOW);
|
||||
Win32::CWindow::StdMsgLoop(&elfViewFrame);
|
||||
return 0;
|
||||
}
|
||||
|
@ -1,7 +1,9 @@
|
||||
#include <windows.h>
|
||||
#include "PsfFs.h"
|
||||
#include "StdStream.h"
|
||||
|
||||
using namespace std;
|
||||
using namespace Framework;
|
||||
|
||||
int WINAPI WinMain(HINSTANCE instance, HINSTANCE prevInstance, char* params, int showCmd)
|
||||
{
|
||||
@ -10,5 +12,10 @@ int WINAPI WinMain(HINSTANCE instance, HINSTANCE prevInstance, char* params, int
|
||||
CPsfFs PsfFs(filename.c_str());
|
||||
const CPsfFs::FILE* file = PsfFs.GetFile("psf2.irx");
|
||||
|
||||
{
|
||||
CStdStream outputStream("psf2.irx", "wb");
|
||||
outputStream.Write(file->data, file->size);
|
||||
}
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user