view syl_window.h @ 136:fc3815b7462f

Javascript backend now produces working code for some simple examples, still more of the standard lib that needs to be ported.
author Mike Pavone <pavone@retrodev.com>
date Sun, 14 Nov 2010 23:07:55 -0500
parents 76568becd6d6
children
line wrap: on
line source

#ifndef SYL_WINDOW_H_
#define SYL_WINDOW_H_

#include "datum.h"
#include "interp.h"
#include "vis_threading.h"

#ifdef CPLUSPLUS

#include <gui/window.h>


class os_window : public os::Window
{
public:
	os_window(datum * vis_wind);
	~os_window();
	void HandleMessage(os::Message * msg);
//	void DispatchMessage(os::Message * pcMsg, os::Handler * pcHandler);
//	os::View *SetFocusNoHandler(os::View * new_focus );
//private:
//	os::View * current_focus;
	datum * vis_wind;
};


struct vis_window_shown
{
	os_window * wind;
#else
typedef struct
{
	void * wind;
#endif
	VIS_CRITICAL_SECTION(lock)
	datum * title;
	double width;
	double height;
	double xpos;
	double ypos;
	queue_entry * wait_entry;
	int next_msg_code;
	datum * handler_list;
	worker_instance instance;
	datum * widget_types;
	BOOL is_open;
#ifdef CPLUSPLUS
};
#else
} vis_window_shown;
#endif

#ifdef CPLUSPLUS
extern "C" {
void add_widget_shared(vis_window_shown * window_show, datum * widget_datum, char * name, double xpos, double ypos, queue_entry * worker_entry, os::View * parent_view);
}
#endif

#endif //SYL_WINDOW_H_