ReactOS  0.4.15-dev-1206-g731eddf
appview.h File Reference
#include "rapps.h"
#include "rosui.h"
#include "crichedit.h"
#include "asyncinet.h"
#include <shlobj_undoc.h>
#include <shlguid_undoc.h>
#include <atlbase.h>
#include <atlcom.h>
#include <atltypes.h>
#include <atlwin.h>
#include <wininet.h>
#include <shellutils.h>
#include <rosctrls.h>
#include <gdiplus.h>
#include <math.h>
Include dependency graph for appview.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  __ScrnshotDownloadParam
 
class  CAppRichEdit
 
class  CAppScrnshotPreview
 
class  CAppInfoDisplay
 
class  CAppsListView
 
struct  CAppsListView::SortContext
 
class  CMainToolbar
 
class  CSearchBar
 
class  CComboBox
 
class  CApplicationView
 

Macros

#define LISTVIEW_ICON_SIZE   32
 
#define BROKENIMG_ICON_SIZE   96
 
#define SCRNSHOT_MAX_ASPECT_RAT   2.5
 
#define INFO_DISPLAY_PADDING   10
 
#define RICHEDIT_MIN_WIDTH   160
 
#define TOOLBAR_PADDING   6
 
#define WM_RAPPS_DOWNLOAD_COMPLETE   (WM_USER + 1)
 
#define WM_RAPPS_RESIZE_CHILDREN   (WM_USER + 2)
 
#define TIMER_LOADING_ANIMATION   1
 
#define LOADING_ANIMATION_PERIOD   3
 
#define LOADING_ANIMATION_FPS   18
 
#define PI   3.1415927
 
#define STATEIMAGETOINDEX(x)   (((x) & LVIS_STATEIMAGEMASK) >> 12)
 
#define STATEIMAGE_UNCHECKED   1
 
#define STATEIMAGE_CHECKED   2
 

Typedefs

typedef struct __ScrnshotDownloadParam ScrnshotDownloadParam
 

Enumerations

enum  SCRNSHOT_STATUS { SCRNSHOT_PREV_EMPTY, SCRNSHOT_PREV_LOADING, SCRNSHOT_PREV_IMAGE, SCRNSHOT_PREV_FAILED }
 
enum  APPLICATION_VIEW_TYPE { AppViewTypeEmpty, AppViewTypeAvailableApps, AppViewTypeInstalledApps }
 

Functions

int ScrnshotDownloadCallback (pASYNCINET AsyncInet, ASYNC_EVENT Event, WPARAM wParam, LPARAM lParam, VOID *Extension)
 

Macro Definition Documentation

◆ BROKENIMG_ICON_SIZE

#define BROKENIMG_ICON_SIZE   96

Definition at line 26 of file appview.h.

◆ INFO_DISPLAY_PADDING

#define INFO_DISPLAY_PADDING   10

Definition at line 32 of file appview.h.

◆ LISTVIEW_ICON_SIZE

#define LISTVIEW_ICON_SIZE   32

Definition at line 23 of file appview.h.

◆ LOADING_ANIMATION_FPS

#define LOADING_ANIMATION_FPS   18

Definition at line 55 of file appview.h.

◆ LOADING_ANIMATION_PERIOD

#define LOADING_ANIMATION_PERIOD   3

Definition at line 54 of file appview.h.

◆ PI

#define PI   3.1415927

Definition at line 58 of file appview.h.

◆ RICHEDIT_MIN_WIDTH

#define RICHEDIT_MIN_WIDTH   160

Definition at line 35 of file appview.h.

◆ SCRNSHOT_MAX_ASPECT_RAT

#define SCRNSHOT_MAX_ASPECT_RAT   2.5

Definition at line 29 of file appview.h.

◆ STATEIMAGE_CHECKED

#define STATEIMAGE_CHECKED   2

Definition at line 66 of file appview.h.

◆ STATEIMAGE_UNCHECKED

#define STATEIMAGE_UNCHECKED   1

Definition at line 65 of file appview.h.

◆ STATEIMAGETOINDEX

#define STATEIMAGETOINDEX (   x)    (((x) & LVIS_STATEIMAGEMASK) >> 12)

Definition at line 61 of file appview.h.

◆ TIMER_LOADING_ANIMATION

#define TIMER_LOADING_ANIMATION   1

Definition at line 52 of file appview.h.

◆ TOOLBAR_PADDING

#define TOOLBAR_PADDING   6

Definition at line 38 of file appview.h.

◆ WM_RAPPS_DOWNLOAD_COMPLETE

#define WM_RAPPS_DOWNLOAD_COMPLETE   (WM_USER + 1)

Definition at line 41 of file appview.h.

◆ WM_RAPPS_RESIZE_CHILDREN

#define WM_RAPPS_RESIZE_CHILDREN   (WM_USER + 2)

Definition at line 42 of file appview.h.

Typedef Documentation

◆ ScrnshotDownloadParam

Enumeration Type Documentation

◆ APPLICATION_VIEW_TYPE

Enumerator
AppViewTypeEmpty 
AppViewTypeAvailableApps 
AppViewTypeInstalledApps 

Definition at line 70 of file appview.h.

◆ SCRNSHOT_STATUS

Enumerator
SCRNSHOT_PREV_EMPTY 
SCRNSHOT_PREV_LOADING 
SCRNSHOT_PREV_IMAGE 
SCRNSHOT_PREV_FAILED 

Definition at line 44 of file appview.h.

45 {
46  SCRNSHOT_PREV_EMPTY, // show nothing
47  SCRNSHOT_PREV_LOADING, // image is loading (most likely downloading)
48  SCRNSHOT_PREV_IMAGE, // display image from a file
49  SCRNSHOT_PREV_FAILED // image can not be shown (download failure or wrong image)
50 };

Function Documentation

◆ ScrnshotDownloadCallback()

int ScrnshotDownloadCallback ( pASYNCINET  AsyncInet,
ASYNC_EVENT  Event,
WPARAM  wParam,
LPARAM  lParam,
VOID Extension 
)

Definition at line 437 of file appview.cpp.

444 {
446  switch (Event)
447  {
448  case ASYNCINET_DATA:
451  break;
452  case ASYNCINET_COMPLETE:
453  CloseHandle(DownloadParam->hFile);
455  break;
456  case ASYNCINET_CANCELLED:
457  CloseHandle(DownloadParam->hFile);
459  break;
460  case ASYNCINET_ERROR:
461  CloseHandle(DownloadParam->hFile);
463  break;
464  default:
465  ATLASSERT(FALSE);
466  break;
467  }
468  return 0;
469 }
BOOL WINAPI WriteFile(IN HANDLE hFile, IN LPCVOID lpBuffer, IN DWORD nNumberOfBytesToWrite OPTIONAL, OUT LPDWORD lpNumberOfBytesWritten, IN LPOVERLAPPED lpOverlapped OPTIONAL)
Definition: rw.c:24
_Must_inspect_result_ _In_ PFILE_OBJECT _In_opt_ PLARGE_INTEGER _In_ ULONG _In_ FLT_IO_OPERATION_FLAGS _Out_opt_ PULONG BytesWritten
Definition: fltkernel.h:1293
#define CloseHandle
Definition: compat.h:598
#define ERROR_SUCCESS
Definition: deptool.c:10
#define ATLASSERT(x)
Definition: CComVariant.cpp:10
UINT_PTR WPARAM
Definition: windef.h:207
WPARAM wParam
Definition: combotst.c:138
#define FALSE
Definition: types.h:117
smooth NULL
Definition: ftsmooth.c:416
LONG_PTR LPARAM
Definition: windef.h:208
#define WM_RAPPS_DOWNLOAD_COMPLETE
Definition: appview.h:41
unsigned long DWORD
Definition: ntddk_ex.h:95
#define ERROR_CANCELLED
Definition: winerror.h:726
CONST void * LPCVOID
Definition: windef.h:191
#define SendMessage
Definition: winuser.h:5818
LPARAM lParam
Definition: combotst.c:139
_Inout_opt_ PUNICODE_STRING Extension
Definition: fltkernel.h:1092

Referenced by CAppScrnshotPreview::DisplayImage().