Skip to content

Commit

Permalink
Bug fix for when primary monitor is not leftmost monitor.
Browse files Browse the repository at this point in the history
  • Loading branch information
evangreen committed Mar 17, 2015
1 parent dc22e79 commit db7b456
Showing 1 changed file with 5 additions and 11 deletions.
16 changes: 5 additions & 11 deletions phosphor2.c
Original file line number Diff line number Diff line change
Expand Up @@ -456,8 +456,8 @@ Return Value:
APPLICATION_NAME,
APPLICATION_NAME,
WS_VISIBLE | WS_POPUP,
0,
0,
GetSystemMetrics(SM_XVIRTUALSCREEN),
GetSystemMetrics(SM_YVIRTUALSCREEN),
GetSystemMetrics(SM_CXVIRTUALSCREEN),
GetSystemMetrics(SM_CYVIRTUALSCREEN),
NULL,
Expand Down Expand Up @@ -1380,7 +1380,7 @@ Return Value:
ULONG Blue;
COLORREF BlurColor;
COLORREF BrightColor;
UCHAR Character;
CHAR Character;
ULONG CharacterCount;
ULONG CharacterIndex;
ULONG FadeIndex;
Expand Down Expand Up @@ -1830,6 +1830,8 @@ Return Value:
}
}

SelectObject(Destination, OriginalPen);

CreateCharacterEnd:
if (Pen != NULL) {
DeleteObject(Pen);
Expand Down Expand Up @@ -2570,7 +2572,6 @@ Return Value:
ULONG FullNameLength;
PSTR *NewFiles;
ULONG NewMax;
BOOLEAN Result;

FullName = NULL;
FullNameLength = strlen(Filename);
Expand All @@ -2584,7 +2585,6 @@ Return Value:

FullName = malloc(FullNameLength + 1);
if (FullName == NULL) {
Result = FALSE;
goto AddFileEnd;
}

Expand All @@ -2609,7 +2609,6 @@ Return Value:

NewFiles = malloc(NewMax * sizeof(PSTR));
if (NewFiles == NULL) {
Result = FALSE;
goto AddFileEnd;
}

Expand All @@ -2628,7 +2627,6 @@ Return Value:
//

FullName = NULL;
Result = TRUE;

AddFileEnd:
if (FullName != NULL) {
Expand Down Expand Up @@ -2673,7 +2671,6 @@ Return Value:
PDIRECTORY_SEARCH NewSearch;
PSTR NewTerm;
ULONG NewMax;
BOOLEAN Result;

NewDirectory = NULL;
NewTerm = NULL;
Expand All @@ -2689,7 +2686,6 @@ Return Value:

NewSearch = malloc(Length);
if (NewSearch == NULL) {
Result = FALSE;
goto AddDirectoryEnd;
}

Expand Down Expand Up @@ -2721,7 +2717,6 @@ Return Value:

NewDirectories = malloc(NewMax * sizeof(PDIRECTORY_SEARCH));
if (NewDirectories == NULL) {
Result = FALSE;
goto AddDirectoryEnd;
}

Expand All @@ -2743,7 +2738,6 @@ Return Value:
//

NewSearch = NULL;
Result = TRUE;

AddDirectoryEnd:
if (NewSearch != NULL) {
Expand Down

0 comments on commit db7b456

Please sign in to comment.