better solution

git-svn-id: http://svn2.nishi.boats/svn/milsko/trunk@25 b9cfdab3-6d41-4d17-bbe4-086880011989
This commit is contained in:
NishiOwO
2025-09-28 13:31:37 +00:00
parent a00e5355e8
commit 5a318e6160
4 changed files with 9 additions and 3 deletions

View File

@@ -7,7 +7,7 @@ CFLAGS = -fPIC -Iinclude -D_MILSKO
LDFLAGS =
LIBS =
L_OBJS = src/ds.o src/core.o
L_OBJS = src/ds.o src/core.o src/default.o
L_OBJS += src/window.o
ifeq ($(TARGET),NetBSD)

View File

@@ -2,6 +2,8 @@
#ifndef __MILSKO_DEFAULT_H__
#define __MILSKO_DEFAULT_H__
#define MILSKO_BACKGROUND "#ddd"
#include <Milsko/MachDep.h>
MILSKODECL const char* MilskoDefaultBackground;
#endif

4
src/default.c Normal file
View File

@@ -0,0 +1,4 @@
/* $Id$ */
#include <Milsko/Milsko.h>
const char* MilskoDefaultBackground = "#ddd";

View File

@@ -2,7 +2,7 @@
#include <Milsko/Milsko.h>
static void create(MilskoWidget handle) {
MilskoSetText(handle, MilskoNbackground, MILSKO_BACKGROUND);
MilskoSetText(handle, MilskoNbackground, MilskoDefaultBackground);
}
static void draw(MilskoWidget handle) {