BBC BASIC for Windows
« Double clicks and multi windows »

Welcome Guest. Please Login or Register.
Apr 5th, 2018, 9:56pm



ATTENTION MEMBERS: Conforums will be closing it doors and discontinuing its service on April 15, 2018.
Ad-Free has been deactivated. Outstanding Ad-Free credits will be reimbursed to respective payment methods.

If you require a dump of the post on your message board, please come to the support board and request it.


Thank you Conforums members.

BBC BASIC for Windows Resources
Online BBC BASIC for Windows documentation
BBC BASIC for Windows Beginners' Tutorial
BBC BASIC Home Page
BBC BASIC on Rosetta Code
BBC BASIC discussion group
BBC BASIC for Windows Programmers' Reference

« Previous Topic | Next Topic »
Pages: 1  Notify Send Topic Print
 thread  Author  Topic: Double clicks and multi windows  (Read 448 times)
KenDown
Full Member
ImageImageImage


member is offline

Avatar




PM


Posts: 181
xx Double clicks and multi windows
« Thread started on: Jun 25th, 2016, 5:37pm »

I'm playing around with using double clicks in one of my programs and have managed to get it to work in a test program.

Feeling pleased with myself I then transferred the snippets of code to all the right places in the actual program and I can't get double-clicks. If I trap @msg% with a value of 513 - which appears to be a single click - that works fine. If I use the value 515 (for double clicks) nothing.

The problem appears to be that my program uses multiple output windows. I have guessed that I need to alter the @hwnd% in the initialisation code to the handle of the window that I want to accept the double-clicks, but whether using hw2% or !hw2%, the double-clicks remain unrecognised.

Can anyone tell me whether multiple windows can accept double-clicks? Also whether I do need to change @hwnd%?

Many thanks.
User IP Logged

Zaphod
Guest
xx Re: Double clicks and multi windows
« Reply #1 on: Jun 26th, 2016, 12:44am »

It looks as if Multiwin.bbc library does not pass on that interrupt.
However it would also appear that it would be easy to modify to add in your required value.
Code:
      mov eax,[esp+8]
      cmp eax,15:jz near T%
      cmp eax,2 :jz D%
      cmp eax,&200:jz V%
      cmp eax,&100:jz F%
      cmp eax,&104:jz F%
      cmp eax,&201:jz F%
      cmp eax,&204:jz F%
      cmp eax,&207:jz F%
      cmp eax,&403:jz F%
      cmp eax,&111:jz F%
      cmp eax,&114:jz F%
      cmp eax,&115:jz F%
      jmp "DefWindowProc"
 

Just add your interrupt to the list, you want &203.
User IP Logged

KenDown
Full Member
ImageImageImage


member is offline

Avatar




PM


Posts: 181
xx Re: Double clicks and multi windows
« Reply #2 on: Jun 26th, 2016, 08:12am »

Wow! Brilliant! Now my program works as I want - the only downside is that now, if I share it with anyone, I'll have to share the modified MultiWin library - I know the libraries are incorporated in the compiled executable, but not if I share the code.

Thanks again.
User IP Logged

Zaphod
Guest
xx Re: Double clicks and multi windows
« Reply #3 on: Jun 26th, 2016, 3:30pm »

Quote:
the only downside is that now, if I share it with anyone, I'll have to share the modified MultiWin library

I don't see that as a problem.
You can just copy the modified library code into your into your program rather than install it. Indeed that would be better so you don't forget that it needs the modified version. And since BB4W and thus Multiwin isn't going to get updated any time soon, if ever, it should remain up to date.

Glad it works for you anyway.

User IP Logged

KenDown
Full Member
ImageImageImage


member is offline

Avatar




PM


Posts: 181
xx Re: Double clicks and multi windows
« Reply #4 on: Jun 26th, 2016, 6:02pm »

Just in case anyone is wondering what I wanted it for, it's my "PowerPoint" improvement. I use the right-mouse button to underline, so it always draws a perfect horizontal line.

Recently my laser pointer cum remote gave up the ghost and I found a nice one on Amazon that was an "air mouse" as well as pointer and remote. Great, I thought, now I can underline without having to stoop to the mouse on the table.

No, the button which gives you a right click is tiny and hard to operate, and as soon as you press it the air mouse stops working - you can't move the pointer at all. Grrrr.

So now I simply double click and hold, then move the air mouse and get a perfect underline again.

Thanks once more.
User IP Logged

Pages: 1  Notify Send Topic Print
« Previous Topic | Next Topic »

| |

This forum powered for FREE by Conforums ©
Terms of Service | Privacy Policy | Conforums Support | Parental Controls