download jview.c
Language: C
Copyright: Copyright 1999 Sim IJskes Copyright 1999 others......
LOC: 78
Project Info
BeKaffe
Server: SourceForge
Type: cvs
...fe\libraries\clib\awt\BeOS\
   cbd.c
   clr.c
   evt.c
   fnt.c
   gra.c
   graphics.c
   graphics.h
   img.c
   imggif.c
   imgjpeg.c
   imgpng.c
   japp.c
   japp.h
   jview.c
   jview.h
   jwindow.c
   jwindow.h
   keysyms.h
   libawt.la
   Makefile.am
   Makefile.in
   tlk.c
   tlkprops.h
   toolkit.h
   wnd.c

/**
 * jview.c 
 *
 *	(c) Copyright 1999 others......
 *	(c) Copyright 1999 Sim IJskes
 *
 * See the file "license.terms" for information on usage and redistribution 
 * of this file. 
 */

#include "japp.h"

#include "toolkit.h"

#include "jview.h"


const char * sourceTag = "*wnd*";


void
jView::Draw(BRect update)
{
	DBG(AWT_EVT, printf( "jView::Draw(" ));
	DBG(AWT_EVT, update.PrintToStream());
	DBG(AWT_EVT, printf( "\n" ));

#if 0
  DBG(AWT_EVT, printf("Draw\n"));

// !!! NOT THE BEST PLACE, 
//     it would be better to intercept events before they are dispatched to the handlers
//     (see event_hook)

  BMessage * msg = new BMessage();

  msg->what = UPDATE_EVENT;					/* custom update event */
  msg->AddPointer(sourceTag, Window()); 
  msg->AddRect("frame", Frame());           /* update the entire frame */
  
  bigtime_t t = system_time();
  msg->AddInt64("when", t);

	update.PrintToStream();

	javaApp->AddMessage( msg );
#endif
} 


void
jView::KeyDown(const char *bytes, int32 numBytes)
{
	DBG(AWT_EVT, printf("jView::KeyDown\n"));
}

void
jView::KeyUp(const char *bytes, int32 numBytes)
{
	DBG(AWT_EVT, printf("jView::KeyUp\n"));
}

void
jView::MouseDown(BPoint point)
{
	DBG(AWT_EVT, printf("jView::MouseDown\n"));
}

void
jView::MouseUp(BPoint point)
{
	DBG(AWT_EVT, printf("jView::MouseUp\n"));
}

void
jView::MouseMoved(BPoint point, uint32 transit, const BMessage *message)
{
	DBG(AWT_EVT, printf("jView::MouseMoved\n"));
}

void
jView::FrameMoved(BPoint parentPoint)
{
	DBG(AWT_EVT, printf("jView::FrameMoved\n"));
	BView::FrameMoved( parentPoint );
}

void
jView::FrameResized(float width, float height)
{
	DBG(AWT_EVT, printf("jView::FrameResized\n"));
	BView::FrameResized( width, height );
}

void
jView::WindowActivated(bool active)
{
	DBG(AWT_EVT, printf("BView::WindowActivated\n"));
}

void
jView::MessageReceived(BMessage * msg)
{
	DBG(AWT_EVT, printf("BView::MessageReceived\n"));
	DBG(AWT_EVT, printf( "jview <<<<\n" ));
	DBG(AWT_EVT, msg->PrintToStream());

	if (msg)
	switch(msg->what)
	{
		default:
			BView::MessageReceived(msg);
	}

	DBG(AWT_EVT, printf( "<<<< jview\n" ));
}


About Koders | Resources | Downloads | Support | Black Duck | Submit Project | Terms of Service | DMCA | Privacy Policy | Site Map| Contact Us