Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.


Welcome, Guest
Guest Settings
Help

Thread: XE7 TOpenDialog weirdness on OS X 10.9.5 Mavericks


This question is not answered. Helpful answers available: 0. Correct answers available: 1.


Permlink Replies: 18 - Last Post: Mar 20, 2015 11:07 AM Last Post By: Jean-Marc Piuze
Grant Beattie

Posts: 77
Registered: 11/29/01
XE7 TOpenDialog weirdness on OS X 10.9.5 Mavericks  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Oct 27, 2014 3:35 PM
All I have on my form is a TButton and a TOpenDialog and I have set none of the properties (all I did was drop it on the form). The button executes it:

var
  Form1: TForm1;
 
implementation
 
{$R *.fmx}
 
procedure TForm1.Button1Click(Sender: TObject);
begin
   OpenDialog1.Execute();
end;
 
end.


What happens is that if I choose the "details" view of the file explore for the dialog (not the icons view but the one that shows the file detail line by line), the dialog opens EMPTY.

https://dl.dropboxusercontent.com/u/46079881/screenshot1.jpg

If I select icon view the files show up

https://dl.dropboxusercontent.com/u/46079881/screenshot2.jpg

and if I move back to the details view the files now show up.

https://dl.dropboxusercontent.com/u/46079881/screenshot3.jpg

Everything seems really sluggish on Mavericks but this is the first thing I could put my finger on as being an absolute bug. Same thing happens in C++.

Can someone please verify this for me?

I have done the "Update Local File Cache" for the SDK. Not sure what else to try.

Runs OK on Win32 and last I checked OK on Mountain Lion 10.8.5 too (but of course it's a different Mac).

---

Edited by: Grant Beattie on Oct 28, 2014 9:56 AM to add screen caps.
Grant Beattie

Posts: 77
Registered: 11/29/01
Re: XE7 TOpenDialog weirdness on OS X 10.9.5 Mavericks  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Oct 28, 2014 9:46 AM   in response to: Grant Beattie in response to: Grant Beattie
I just tried this on OS X 10.9.5 Mavericks with the MacOSX 10.10 SDK using the XE7 compiler and the result is the same.

I added screen caps above to illustrate the issue.

At this point I don't know if this is an issue with the MacOS, the iMac itself, something in my code (but in reality there isn't any code of my owner here to speak of), in XE7 or what?! I do have XE6 and XE5 around so I can test there as well I guess. This is pretty odd, and with the permutation of XE compilers, the OSX SDKs and the target OS on the target Mac it's getting a little nuts.
Eli M

Posts: 1,346
Registered: 11/9/13
Re: XE7 TOpenDialog weirdness on OS X 10.9.5 Mavericks
Helpful
Click to report abuse...   Click to reply to this thread Reply
  Posted: Oct 28, 2014 10:02 AM   in response to: Grant Beattie in response to: Grant Beattie
I tried it on XE7 & MacInCloud which says it is 10.8.5 and everything seemed to work okay. Which you said worked for you too so not a big help but I don't have any other Macs.
Grant Beattie

Posts: 77
Registered: 11/29/01
Re: XE5/XE6/XE7 TOpenDialog weirdness on OS X 10.9.5 Mavericks  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Oct 28, 2014 10:30 AM   in response to: Eli M in response to: Eli M
I just tested on XE5 and XE6 with SDK MacOSX 10.9.5 and it's still bad.

I had to install RAD PAServer XE5 and XE6 and then loaded the above SDK fresh into a two new directories on my PC (XE5_SDKs and XE6_SDKs). I'm sure that wasn't necessary but I wanted to eliminate possibilities.

Where do these dialogs come from? Are they built into the Mac or supplied somehow from Embarcadero? Sorry for the beginner type question...

---

Edited by: Grant Beattie on Oct 28, 2014 10:59 AM
Douglas Rudd

Posts: 314
Registered: 5/16/97
Re: XE7 TOpenDialog weirdness on OS X 10.9.5 Mavericks  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Oct 28, 2014 4:23 PM   in response to: Grant Beattie in response to: Grant Beattie
It works on mine:
http://i.imgur.com/E2O4Dw7.png

The dialog starts in the view mode that you last closed it in. This opens in last mode ok in all three modes.

Mac OSX ver 10.9.5
MacOSX10.8.5.sdk
Xcode 6.0.1
Brian Hamilton ...

Posts: 556
Registered: 10/14/04
Re: XE7 TOpenDialog weirdness on OS X 10.9.5 Mavericks  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Oct 28, 2014 6:32 PM   in response to: Douglas Rudd in response to: Douglas Rudd
maybe its a permissions issues re the problems some are having then?
Douglas Rudd

Posts: 314
Registered: 5/16/97
Re: XE7 TOpenDialog weirdness on OS X 10.9.5 Mavericks  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Oct 28, 2014 7:07 PM   in response to: Brian Hamilton ... in response to: Brian Hamilton ...
Brian Hamilton wrote:
maybe its a permissions issues re the problems some are having then?

On this example all the entitlements were blank. Doesnt make sense that there is a permission that you can view the second time but not the first time.

But I do remember couple weeks ago I had a problem that the open dialog wouldnt show up at all without the entitlement "Read/write access to files selected with the Open and Save Dialog" being checked.
Grant Beattie

Posts: 77
Registered: 11/29/01
Re: XE7 TOpenDialog weirdness on OS X 10.9.5 Mavericks  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Oct 29, 2014 7:08 AM   in response to: Douglas Rudd in response to: Douglas Rudd
Douglas Rudd wrote:
It works on mine:
http://i.imgur.com/E2O4Dw7.png

The dialog starts in the view mode that you last closed it in. This opens in last mode ok in all three modes.

Mac OSX ver 10.9.5
MacOSX10.8.5.sdk
Xcode 6.0.1

That's an interesting combination Douglas. Maybe my mistake is upgrading things? The closest I could get was:

Mac OSX ver 10.9.5
MacOSX10.8.5.sdk - taken from a different mac
Xcode 6.1

And it still fails! Do older versions of XCode live somewhere? I will look for 6.0.1. Also any chance you want to swap projects or even .apps?
Douglas Rudd

Posts: 314
Registered: 5/16/97
Re: XE7 TOpenDialog weirdness on OS X 10.9.5 Mavericks
Helpful
Click to report abuse...   Click to reply to this thread Reply
  Posted: Oct 29, 2014 9:05 AM   in response to: Grant Beattie in response to: Grant Beattie
The SDK was what was originally installed when XE7 came out. Never changed it. I don't remember if I updated Xcode. This is a Mac Mini.

On TOpendialog there are lots of properties like Filter and InitialDir. Does it help if you set any of those?

Download this test Mac app I made. See if it works right. Maybe its just something wrong with your computer.
http://i-logic.com/temp/project5.zip
Grant Beattie

Posts: 77
Registered: 11/29/01
Re: XE7 TOpenDialog weirdness on OS X 10.9.5 Mavericks  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Oct 29, 2014 9:32 AM   in response to: Douglas Rudd in response to: Douglas Rudd
Douglas Rudd wrote:
The SDK was what was originally installed when XE7 came out. Never changed it. I don't remember if I updated Xcode. This is a Mac Mini.

On TOpendialog there are lots of properties like Filter and InitialDir. Does it help if you set any of those?

Download this test Mac app I made. See if it works right. Maybe its just something wrong with your computer.
http://i-logic.com/temp/project5.zip

Interesting. I didn't know you could take a Mini that far. I have one with 10.8 (whatever that was, Lion?) collecting dust and might play with it then.

Anyway this project has the same behaviour as mine! So something with the PC I guess. Thanks, I guess I will take this investigation in a new direction...

BTW, there is no "embarcadero" icon when you run the program. I guess their .icns file doesn't have the highest res one built in? And for what it's worth, I was under the impression that we weren't supposed to use Mountain Lion SDKs with Mavericks. But who am I to say as I'm the one with the issues...

Edited by: Grant Beattie on Oct 29, 2014 10:03 AM
Grant Beattie

Posts: 77
Registered: 11/29/01
Re: XE7 TOpenDialog weirdness on OS X 10.9.5 Mavericks  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Oct 30, 2014 3:25 PM   in response to: Grant Beattie in response to: Grant Beattie
New development if anyone cares.

Grant Beattie wrote:

Anyway this project has the same behaviour as mine! So something with the PC I guess. Thanks, I guess I will take this investigation in a new direction...

So I signed up for MacInCloud and am hooked up to another 10.9.5 machine. Here is a screen cap of the failure on that machine too (this is the Project5.app that Doug posted).

https://dl.dropboxusercontent.com/u/46079881/macinclound.jpg

What I learned was that if the starting directory is something like Applications, then I can see all the files in the List View mode right off the bat. Now if the starting directory is something of "mine" like Documents or Downloads, then you can't see the List View the first time is opens, but you can the second. What I mean by that ... it doesn't matter which view you start with, the first time you try List View it's empty. If you go to Icons then come back then you can see the files. I need to try a few other tests with my app but I'm starting to think it's some setting on the Mac, although I've investigated that a lot and nothing notable yet...
Douglas Rudd

Posts: 314
Registered: 5/16/97
Re: XE7 TOpenDialog weirdness on OS X 10.9.5 Mavericks  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Oct 30, 2014 5:09 PM   in response to: Grant Beattie in response to: Grant Beattie
On further checking, I am seeing some weirdness. On the previous test I just pressed the button and the opendialog came up with list of files, so it was ok. Now when I try going to other folders in the "Favorites" list on the left they show up blank. And changing view modes make a difference. Various things happen according to where you start up in. Probably like what you are getting.

I will look into it some more.
Douglas Rudd

Posts: 314
Registered: 5/16/97
Re: XE7 TOpenDialog weirdness on OS X 10.9.5 Mavericks  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Oct 30, 2014 7:42 PM   in response to: Douglas Rudd in response to: Douglas Rudd
I think I got it figured out.

I know I made an app a couple weeks ago that work fine. I tried to figure out what the difference is.

1. you need entitlement: "Read/write access to files selected with the Open and Save Dialog" checked.
2. you need <key>com.apple.security.app-sandbox</key> in the entitlements.plist, which I think you can only get in there when you build for Application Store with code signing.

In this picture you see the bad one always has three view buttons.
The good one always has four view buttons.
http://i.imgur.com/omQVPrd.png

You might have to wait a second for it to load the list, but it works as expected.
Grant Beattie

Posts: 77
Registered: 11/29/01
Re: XE7 TOpenDialog weirdness on OS X 10.9.5 Mavericks  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Oct 31, 2014 6:29 AM   in response to: Douglas Rudd in response to: Douglas Rudd
Wow, cool. Thanks for that. I will see if I can figure out how to duplicate that and confirm.
Grant Beattie

Posts: 77
Registered: 11/29/01
Re: XE7 TOpenDialog weirdness on OS X 10.9.5 Mavericks  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Nov 4, 2014 10:51 AM   in response to: Grant Beattie in response to: Grant Beattie
Douglas Rudd wrote:

2. you need <key>com.apple.security.app-sandbox</key> in the entitlements.plist, which I think you can only get in there when you build for Application Store with code signing.

Wow I never thought that step would be as hard as it is. I've spent the last few days signing up for this and that at Apple, downloading certificates, examining the keychain, setting up the Provisioning Profiles in XE7 and I can't for the life of me build this sucker for the App Store.

I'm sure there are a few hundred MB of PDF guides in my future... anyone know if Embarcadero has anything recent on this for us Apple newbies? The stuff I've found is for older versions and things have changed enough since XE4 to XE7 and now Mavericks that it's blowing my mind. :-(
Jimmy H

Posts: 1
Registered: 8/10/14
Re: XE7 TOpenDialog weirdness on OS X 10.9.5 Mavericks  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Dec 30, 2014 9:50 AM   in response to: Grant Beattie in response to: Grant Beattie
Grant Beattie wrote:
Douglas Rudd wrote:

2. you need <key>com.apple.security.app-sandbox</key> in the entitlements.plist, which I think you can only get in there when you build for Application Store with code signing.

Wow I never thought that step would be as hard as it is. I've spent the last few days signing up for this and that at Apple, downloading certificates, examining the keychain, setting up the Provisioning Profiles in XE7 and I can't for the life of me build this sucker for the App Store.

Could you elaborate on this please? Did you have to join the Mac Developer Program ($99/year)? Is there a way to achieve this without joing the mac dev program?
Jean-Marc Piuze

Posts: 2
Registered: 3/25/15
Re: XE7 TOpenDialog weirdness on OS X 10.9.5 Mavericks  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Mar 6, 2015 12:27 PM   in response to: Douglas Rudd in response to: Douglas Rudd
Douglas Rudd wrote:
I think I got it figured out.

I know I made an app a couple weeks ago that work fine. I tried to figure out what the difference is.

1. you need entitlement: "Read/write access to files selected with the Open and Save Dialog" checked.
2. you need <key>com.apple.security.app-sandbox</key> in the entitlements.plist, which I think you can only get in there when you build for Application Store with code signing.

In this picture you see the bad one always has three view buttons.
The good one always has four view buttons.
http://i.imgur.com/omQVPrd.png

You might have to wait a second for it to load the list, but it works as expected.

Hi Douglas, Grant,

I am experiencing the exact same problem as you describe here. I also figure out that changing the view for "icons" or "column" solve the further displaying content whatever then choosing Documents, Applications.. folders, or other drives..

I have a old Macbook Pro (2008) running Maverick 10.9.5 (sure I upgrade more ram and running great). So, pretty sure, the actual problem is not related to hardware in used. I work on a multi platform project for OSX and Windows using my second Macbook pro under Win Seven for RAD Studio...

Indeed, this problem (osx only) append each time calling the OpenDialog (execute). Whatever my app is using the same OpenDialog instance each time it is called.

So, I wondering if any of you have fix this now ?

Otherwise, is there a way to set the displaying mode (for the fourth button to appear or not) to a sub component under the OpenDialog.

It seems to me that the missing thing is simply resolved at run time when the app is compile for appStore as you seams saying further at this thread... or solved when the end user simply changed view for "icons".. This lead me things that there might be a solution to set the missing thing just before calling "execute"...!

Thank for any reply.. I am very interested having a solution on this ;)

Jean-Marc..
Grant Beattie

Posts: 77
Registered: 11/29/01
Re: XE7 TOpenDialog weirdness on OS X 10.9.5 Mavericks  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Mar 9, 2015 10:08 AM   in response to: Jean-Marc Piuze in response to: Jean-Marc Piuze
Not really solved as far as I know. The behavior varies with the OSX version. If you ask me, it's impossible to create a substantial desktop app in C++Builder using FM and target recent OSX versions. Using the 3rd party "fix firemonkey dylib" tool you can get closer, but I can't believe you can build something decent that will pass Apple's scrutiny (if you can build it at all). In our case we decided to make our app only available on our own website. We code sign it on the Mac, sandboxing is impossible (hence Apple will frown on it).

Here is a ticket I opened, but there are dozens more.

https://quality.embarcadero.com/browse/RSP-9755

Edited by: Grant Beattie on Mar 9, 2015 10:08 AM
Jean-Marc Piuze

Posts: 2
Registered: 3/25/15
Re: XE7 TOpenDialog weirdness on OS X 10.9.5 Mavericks  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Mar 20, 2015 11:07 AM   in response to: Grant Beattie in response to: Grant Beattie
Grant Beattie wrote:
Not really solved as far as I know. The behavior varies with the OSX version. If you ask me, it's impossible to create a substantial desktop app in C++Builder using FM and target recent OSX versions. Using the 3rd party "fix firemonkey dylib" tool you can get closer, but I can't believe you can build something decent that will pass Apple's scrutiny (if you can build it at all). In our case we decided to make our app only available on our own website. We code sign it on the Mac, sandboxing is impossible (hence Apple will frown on it).

Here is a ticket I opened, but there are dozens more.

https://quality.embarcadero.com/browse/RSP-9755

Edited by: Grant Beattie on Mar 9, 2015 10:08 AM

Grant, it is very kind of you for the reply. Very appreciated !

Thanks a lot.. ;)

Jean-Marc..
Legend
Helpful Answer (5 pts)
Correct Answer (10 pts)

Server Response from: ETNAJIVE02