Merge pull request #85 from alphanu1/alphanu1-patch-78

Xrandr sapmming fix
This commit is contained in:
alphanu1 2018-09-10 17:40:09 +01:00 committed by GitHub
commit 7e7f95f2fe
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 13 additions and 12 deletions

View File

@ -56,20 +56,21 @@ static void x11_display_server_destroy(void *data)
{
sprintf(output,"xrandr -s %dx%d", orig_width, orig_height);
system(output);
}
for (i =0; i < 3; i++)
{
sprintf(output,"xrandr --delmode %s%d %s", "VGA",i ,old_mode);
system(output);
sprintf(output,"xrandr --delmode %s-%d %s", "VGA",i ,old_mode);
system(output);
for (i =0; i < 3; i++)
{
sprintf(output,"xrandr --delmode %s%d %s", "VGA",i ,old_mode);
system(output);
sprintf(output,"xrandr --delmode %s-%d %s", "VGA",i ,old_mode);
system(output);
sprintf(output,"xrandr --delmode %s%d %s", "DVI",i ,old_mode);
system(output);
sprintf(output,"xrandr --delmode %s-%d %s", "DVI",i ,old_mode);
system(output);
sprintf(output,"xrandr --delmode %s%d %s", "DVI",i ,old_mode);
system(output);
sprintf(output,"xrandr --delmode %s-%d %s", "DVI",i ,old_mode);
system(output);
}
}
}
sprintf(output,"xrandr --rmmode %s", old_mode);
system(output);