Changeset View
Changeset View
Standalone View
Standalone View
source/blender/windowmanager/intern/wm_platform_support.c
| Show All 17 Lines | |||||
| */ | */ | ||||
| /** \file | /** \file | ||||
| * \ingroup wm | * \ingroup wm | ||||
| */ | */ | ||||
| #include "wm_platform_support.h" | #include "wm_platform_support.h" | ||||
| #include "wm_window_private.h" | #include "wm_window_private.h" | ||||
| #include <CLG_log.h> | |||||
| #include <WM_types.h> | |||||
| #include <string.h> | #include <string.h> | ||||
| #include "BLI_dynstr.h" | #include "BLI_dynstr.h" | ||||
| #include "BLI_fileops.h" | #include "BLI_fileops.h" | ||||
| #include "BLI_linklist.h" | #include "BLI_linklist.h" | ||||
| #include "BLI_path_util.h" | #include "BLI_path_util.h" | ||||
| #include "BLI_string.h" | #include "BLI_string.h" | ||||
| #include "BLI_sys_types.h" | #include "BLI_sys_types.h" | ||||
| ▲ Show 20 Lines • Show All 163 Lines • ▼ Show 20 Lines | switch (support_level) { | ||||
| } | } | ||||
| } | } | ||||
| wm_platform_support_create_link(link); | wm_platform_support_create_link(link); | ||||
| bool show_message = ELEM( | bool show_message = ELEM( | ||||
| support_level, GPU_SUPPORT_LEVEL_LIMITED, GPU_SUPPORT_LEVEL_UNSUPPORTED); | support_level, GPU_SUPPORT_LEVEL_LIMITED, GPU_SUPPORT_LEVEL_UNSUPPORTED); | ||||
| /* We are running in the background print the message in the console. */ | /* We are running in the background print the message in the console. */ | ||||
| if ((G.background || G.debug & G_DEBUG) && show_message) { | if (show_message) { | ||||
| printf("%s\n\n%s\n%s\n", title, message, link); | CLOG_INFO(WM_LOG_SESSION, "%s\n\n%s\n%s\n", title, message, link); | ||||
| } | } | ||||
| if (G.background) { | if (G.background) { | ||||
| /* Don't show the message-box when running in background mode. | /* Don't show the message-box when running in background mode. | ||||
| * Printing to console is enough. */ | * Printing to console is enough. */ | ||||
| result = true; | result = true; | ||||
| } | } | ||||
| else if (show_message) { | else if (show_message) { | ||||
| WM_ghost_show_message_box( | WM_ghost_show_message_box( | ||||
| title, message, "Find Latest Drivers", "Continue Anyway", link, dialog_options); | title, message, "Find Latest Drivers", "Continue Anyway", link, dialog_options); | ||||
| } | } | ||||
| return result; | return result; | ||||
| } | } | ||||