Author Topic: v2.1.44 b490: PFL starts briefly despite config setting  (Read 1746 times)

Cad

  • Regular
  • *
  • Posts: 2260
  • 'Old school' radio guy (and PC programmer)
    • View Profile
v2.1.44 b490: PFL starts briefly despite config setting
« on: March 15, 2008, 21:00:34 »
A very minor one really, but I have mAirList set to NOT auto-start PFL when clicked, so you have to click the Start PFL button which appears in the dialog box where the PFL player would normally be.

When a playlist item (or Player) is put into PFL, about the first 2s of the item plays on PFL before the dialog is fully opened with the Start PFL button on it.  When the dialog is fully open and initialized, the PFL playout stops.

Obviously, behind the scenes, the PFL player is auto-starting and only THEN checking the config setting and stopping itself.  Is there any way this can be changed so that there is NO playout before the dialog fully opens, or not?

Thanks in advance.
--
BFN
CAD

Torben

  • Administrator
  • Doktor mAirList
  • *****
  • Posts: 16723
    • View Profile
Re: v2.1.44 b490: PFL starts briefly despite config setting
« Reply #1 on: March 16, 2008, 16:17:06 »
What's the exact config option you're talking about? And how do you open the Properties dialog in the first place?

Cad

  • Regular
  • *
  • Posts: 2260
  • 'Old school' radio guy (and PC programmer)
    • View Profile
Re: v2.1.44 b490: PFL starts briefly despite config setting
« Reply #2 on: March 16, 2008, 19:52:30 »
OK, I now know what the problem is. ;D  We will come to that in a moment.

Sorry for confusing you by saying 'options!'  I seem to remember—a long time ago—asking you whether it would be possible to NOT start PFL playback automatically when a PFL window opens.  I had thought that you created a config. option to do that, but after examining every line of all my config files, it appears I have remembered incorrectly :-[.

But as I say, I have worked out what the problem is!  In a Playlist object, clicking the selected item opens its Properties dialog, and clicking the PFL tab in that dialog shows a grey box where the PFL player would be, with a Start PFL button at the bottom of the tab. 

I am lazy ;), so I have a habit of double-clicking Playlist items: the first click selects the item, and the second click opens its Properties; hence my double-click is being processed as if it were two single clicks in succession, yes?  Because I am used to doing this, I also have a habit of double-clicking in the Playlist's icon column to PFL an upcoming item, and that is what causes the problem.

I am guessing that within mAirList, there is a procedure something like IconColumn_OnClick, which handles a single click on the Icon column by first automatically making that item the selected item, and then opening the item's PFL dialog.  If you have single-clicked the icon, that all works fine.  BUT if you double-clicked the icon, things go wrong.  First, the item is selected, then it seems there is an internal struggle between the icon-column specific code (which is trying to open the PFL dialog); and the 'standard' single-click item code, which is trying to open the item's Properties dialog.  It seems that the PFL player dialog is starting up (and already auto-playing) when the single-click code fires and opens the Properties dialog, and somehow 'kills off' the already-playing PFL dialog.

So what you see and hear is a brief PFL playout and the PFL dialog starting to initialise, very quickly followed by the apperance of the item's Properties dialog and the termination of both the (still not fully initialised) PFL dialog and its playout.

Maybe the answer to this would be to add an IconColumn_OnDoubleClick procedure, which simply contains code to execute the IconColumn_OnClick procedure, if that makes sense in Delphi terms?  Remember I'm a VB guy, so I tend to think that way!  Maybe it works differently in Delphi?

I hope that info. will be enough to explain the problem and help you fix it. :)
--
BFN
CAD