MCPcopy Create free account
hub / github.com/buggins/coolreader / OpenFileDialog

Function OpenFileDialog

crengine/Tools/Fb2Test/Fb2Test.cpp:95–116  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

93LRESULT CALLBACK About(HWND, UINT, WPARAM, LPARAM);
94
95lString8 OpenFileDialog( HWND hWndOwner )
96{
97 lString8 fn;
98 OPENFILENAMEA ofn;
99 char str[MAX_PATH] = "";
100 memset( &ofn, 0, sizeof(ofn) );
101 ofn.lStructSize = sizeof( ofn );
102 ofn.hwndOwner = hWndOwner;
103 ofn.lpstrFilter = "All supported files (*.fb2;*.txt;*.rtf;*.zip;*.tcr;*.html;*.epub)\0*.fb2;*.txt;*.rtf;*.zip;*.htm;*.html;*.tcr;*.epub\0FictionBook2 files (*.fb2)\0*.fb2\0ZIP files (*.zip)\0*.zip\0All Files (*.*)\0*.*\0\0";
104 ofn.nFilterIndex = 1;
105 ofn.lpstrFile = str;
106 ofn.nMaxFile = MAX_PATH;
107 ofn.lpstrTitle = "Please select book to open";
108 ofn.Flags = OFN_FILEMUSTEXIST | OFN_PATHMUSTEXIST;
109 ofn.lpstrDefExt = "fb2";
110// ofn.FlagsEx = OFN_EX_NOPLACESBAR;
111 if ( GetOpenFileNameA( &ofn ) )
112 {
113 fn = str;
114 }
115 return fn;
116}
117
118lString8 SaveFileDialog( HWND hWndOwner )
119{

Callers 2

WinMainFunction · 0.85
WndProcFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected