Hi,
On 07/07/2015 03:25 PM, Ingmar Wegner wrote:
Hi community,
my QT5 based workbench is running finally.
Congrats ;-)
But I am facing problems concerning the blueberry framework. I suppose
there have been several changes.
My current issue is that I can not reach the main directory of the
cache folder by
QString cache_path = berry::Platform::GetUserPath().absolutePath();
I saw that it was set to depricated but the mentioned replacement
doesn't work either.
berry::Platform::GetUserLocation() returns null as well. In the docu
it is stated, that null will be returned if the user.home is not set
up. This was working before though! I didn't change anything on my
system other than updating MITK.
By the time that I am calling this the GUI has already been
displayed. So this should be no issue with an object that is not yet
initialized, I guess.
Correct.
At a different location I use the plugin context and changed the
previous implementation to:
QDir cache_dir = context->getDataFile("").absoluteDir(); //returns the
cache_dir of the plugin
and then I move two folders up to reach the top level of the cache
folder. This works fine but I need the plugin context for it.
Yes, this is not how it was intended to work.
Do I have to forward the context in the first situation as well or try
to grab it anyhow? Or am I missing anything to get the GetUserLocation
to work?
There could of course be a bug in CTK. You could check the contents of
the context->getProperty("user.home") return value. This is what should
have been used to initialize the value for the
Platform::GetUserLocation() method. Other than that, you would need to
step through some CTK PluginFramework code which initializes the
framework locations and see if there is something stupid going on.
Cheers,
Sascha
Best,
Ingmar
------------------------------------------------------------------------------
_______________________________________________
mitk-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mitk-users