TIP: Click on subject to list as thread! ANSI
echo: c_plusplus
to: ALL
from: JAVIER KOHEN
date: 1997-06-13 21:21:00
subject: Classes [2/2]

>>>>>>>>>> CSplit: Version 2.2 >>>>>>>>>>
>>>>>>>>>> CSplit: Begin part 2/2 >>>>>>>>>>
    int getButtons() const;
};
class Mouse : public MouseInfo {
    REGS regs;
public:
    enum Reset {
        Soft, Hard
    };
    Mouse(Boolean = True);
    void reset(Reset);
};
#endif  // __MOUSE_H
>>>>>>>>>> CSplit: End file MOUSE.H >>>>>>>>>>
>>>>>>>>>> CSplit: Begin file TEST.CPP >>>>>>>>>>
#include 
#include "mouse.h"
int main()
{
    Mouse mouse(False);
    int buttons;
    cout << "Probando \"Hard\" reset...\n";
    mouse.reset(Mouse::Hard);
    buttons = mouse.getButtons();
    if (buttons != -1) {
        cout << "El mouse est  activo.\n";
        cout << "Tiene: " << buttons << " botones.\n";
    } else {
        cout << "El mouse no est  activo.\n";
    }
    cout << "Probando \"Soft\" reset...\n";
    mouse.reset(Mouse::Soft);
    buttons = mouse.getButtons();
    if (buttons != -1) {
        cout << "El mouse est  activo.\n";
        cout << "Tiene: " << buttons << " botones.\n";
    } else {
        cout << "El mouse no est  activo.\n";
    }
    return 0;
}
>>>>>>>>>> CSplit: End file TEST.CPP >>>>>>>>>>
>>>>>>>>>> CSplit: End part 2/2 crc: 949e >>>>>>>>>>
Thank you very much! :)
Internet: jkohen@tough.com þ Fidonet: 4:900/748.3 þ Sk-Network: 200:201/201.2
Rockernet: 33:300/100.3 þ  Javier Kohen/The_Crusher  þ PGP keyID: 3423EAA9
... A social life?  What board can I download THAT from?
-!- CrusherTag 0.021.
--- Terminate 4.00/Pro
4:900/748.3)
---------------
* Origin: The King of The Ring BBS þ +54-1-OFF-LINE þ TLD 0 - 7

SOURCE: echomail via exec-pc

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.