mirror of
https://gitea.nishi.boats/pyrite-dev/milsko
synced 2025-12-31 06:30:52 +00:00
add
git-svn-id: http://svn2.nishi.boats/svn/milsko/trunk@374 b9cfdab3-6d41-4d17-bbe4-086880011989
This commit is contained in:
@@ -32,7 +32,7 @@ L_CFLAGS = $(DEPINC) $(CFLAGS) -fPIC -D_MILSKO
|
||||
L_LDFLAGS = $(LDFLAGS)
|
||||
L_LIBS = $(LIBS)
|
||||
|
||||
L_OBJS = src/core.o src/default.o src/draw.o src/lowlevel.o src/font.o src/boldfont.o src/error.o src/unicode.o src/color.o src/messagebox.o src/directory.o src/string.o
|
||||
L_OBJS = src/core.o src/default.o src/draw.o src/lowlevel.o src/font.o src/boldfont.o src/error.o src/unicode.o src/color.o src/messagebox.o src/directory.o src/string.o src/filechooser.o
|
||||
L_OBJS += external/ds.o external/image.o
|
||||
L_OBJS += src/widget/window.o src/widget/button.o src/widget/frame.o src/widget/menu.o src/widget/submenu.o src/widget/image.o src/widget/scrollbar.o src/widget/checkbox.o src/widget/label.o src/widget/entry.o src/widget/numberentry.o src/widget/viewport.o src/widget/listbox.o
|
||||
L_OBJS += src/cursor/default.o src/cursor/cross.o src/cursor/text.o
|
||||
|
||||
22
include/Mw/FileChooser.h
Normal file
22
include/Mw/FileChooser.h
Normal file
@@ -0,0 +1,22 @@
|
||||
/* $Id$ */
|
||||
/*!
|
||||
* %file Mw/FileChoose.h
|
||||
* %brief File chooser
|
||||
*/
|
||||
#ifndef __MW_FILECHOOSER_H__
|
||||
#define __MW_FILECHOOSER_H__
|
||||
|
||||
#include <Mw/MachDep.h>
|
||||
#include <Mw/TypeDefs.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
MWDECL MwWidget MwFileChooser(MwWidget handle, const char* title);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -22,6 +22,7 @@
|
||||
#include <Mw/MessageBox.h>
|
||||
#include <Mw/Directory.h>
|
||||
#include <Mw/String.h>
|
||||
#include <Mw/FileChooser.h>
|
||||
|
||||
#include <Mw/Widget/Window.h>
|
||||
#include <Mw/Widget/Menu.h>
|
||||
|
||||
22
src/filechooser.c
Normal file
22
src/filechooser.c
Normal file
@@ -0,0 +1,22 @@
|
||||
/* $Id$ */
|
||||
#include <Mw/Milsko.h>
|
||||
|
||||
MwWidget MwFileChooser(MwWidget handle, const char* title){
|
||||
MwWidget window;
|
||||
MwPoint p;
|
||||
int ww = MwGetInteger(handle, MwNwidth);
|
||||
int wh = MwGetInteger(handle, MwNheight);
|
||||
int w, h;
|
||||
|
||||
p.x = 0;
|
||||
p.y = 0;
|
||||
|
||||
window = MwVaCreateWidget(MwWindowClass, "filechooser", handle, ww, wh, (w = 640), (h = 300),
|
||||
MwNtitle, title,
|
||||
NULL);
|
||||
|
||||
MwLLDetach(window->lowlevel, &p);
|
||||
MwLLMakePopup(window->lowlevel, handle->lowlevel);
|
||||
|
||||
return window;
|
||||
}
|
||||
Reference in New Issue
Block a user