view TaskManager/Test/test_render/Button.cpp @ 203:1eba8570808c draft

fix CreateSpan::run
author gongo@localhost.localdomain
date Mon, 26 Jan 2009 18:30:35 +0900
parents 1fd0107ebb25
children 59f4129a9562
line wrap: on
line source

#include "Button.h"

void
Button::push_work(void)
{
#if 0
    if (hold) {
	push = 0;
    } else {
	push = 1;
    }
#else
    push = (!hold)*1;
#endif

    hold = 1;
    release = 0;
}

void
Button::release_work(void)
{
    push = 0;
    hold = 0;
    release = 1;
}

int
Button::isPush(void)
{
    return push;
}

int
Button::isHold(void)
{
    return hold;
}

int
Button::isRelease(void)
{
    return release;
}