Semi-OT: Non-Specific Question for Developers

This new stand alone release based on the legendary War in the Pacific from 2 by 3 Games adds significant improvements and changes to enhance game play, improve realism, and increase historical accuracy. With dozens of new features, new art, and engine improvements, War in the Pacific: Admiral's Edition brings you the most realistic and immersive WWII Pacific Theater wargame ever!

Moderators: wdolson, MOD_War-in-the-Pacific-Admirals-Edition

Post Reply
CaptDave
Posts: 651
Joined: Thu Jun 20, 2002 9:11 pm
Location: Federal Way, WA

Semi-OT: Non-Specific Question for Developers

Post by CaptDave »

In all versions of WitP, when you click on a scroll bar the position jumps to where it was clicked, rather than moving one page at a time. I, and many others on another forum, have noticed an increasing number of applications where clicking in a scroll bar results in a continuous scroll until it reaches the end or the scroll bar is clicked again. If anyone can answer without giving away the deep, dark secrets of the code, might these two "features" be related?

Alternatively, does anyone know what causes the continuous scroll? It's something we all find annoying, and would like to figure out how to eliminate it in the open source program we're discussing in that other forum.

Personally, I'm guessing it's related to code written to accommodate tablets and phones, but the last major language I programmed in is FORTRAN so it's just a guess.
wdolson
Posts: 7648
Joined: Tue Jun 27, 2006 9:56 pm
Location: Near Portland, OR

RE: Semi-OT: Non-Specific Question for Developers

Post by wdolson »

The continuous scroll is part of the standard Windows control. It's been that way since Windows 95 if I remember correctly.

To do the jump scroll like WitP does, you have to write your own handler for the scroll function. When we inherited the code for WitP, this was essentially already there and we didn't mess with it.

I program in C and C++ (not .NET). Other than what is in the WitP code, I have never looked at what it would take to do a jump scroll (I never looked that closely at the WitP code for this because we were focused on other things), but essentially you need to catch the Windows message for scrolling for the window you're dealing with. I believe it's WM_SCROLL. Then you need to write your own handler for the message.

Bill
WitP AE - Test team lead, programmer
Image
CaptDave
Posts: 651
Joined: Thu Jun 20, 2002 9:11 pm
Location: Federal Way, WA

RE: Semi-OT: Non-Specific Question for Developers

Post by CaptDave »

Thanks, Bill, though I think I might have been unclear. I was referring to a single click inducing a continuous scroll; normal behavior, like in these forums, is that a single click scrolls down one page, while a click and hold of course starts a continuous scroll. What I've seen -- and this is mostly on Explorer-equivalent screens for download locations -- is that a single click causes the continuous scroll.

The specific problem we were discussing in the other forum turned out to be a driver issue, as it happens. Some people also had trouble with gunk in their mice and trackpads, so there was no one answer.
wdolson
Posts: 7648
Joined: Tue Jun 27, 2006 9:56 pm
Location: Near Portland, OR

RE: Semi-OT: Non-Specific Question for Developers

Post by wdolson »

Sticky mice can cause all sorts of frustrating things.

Bill
WitP AE - Test team lead, programmer
Image
CaptDave
Posts: 651
Joined: Thu Jun 20, 2002 9:11 pm
Location: Federal Way, WA

RE: Semi-OT: Non-Specific Question for Developers

Post by CaptDave »

Yep. Not my particular problem, in this case, but seemed to be the issue for everyone else. (My laptop has a trackpad, but it's not a separate rubberized pad -- it's molded into the shell and thus sealed.)
Post Reply

Return to “War in the Pacific: Admiral's Edition”