JAVA- Registering a context menu interceptor in addon.

Creating a macro - Writing a Script - Using the API (OpenOffice Basic, Python, BeanShell, JavaScript)
hanya
Volunteer
Posts: 885
Joined: Fri Nov 23, 2007 9:27 am
Location: Japan

Re: JAVA- Registering a context menu interceptor in addon.

Post by hanya »

I'm sorry, src directory is not inserted into the archive.
ExampleJob.zip
with source code
(22.82 KiB) Downloaded 223 times
Please, edit this thread's initial post and add "[Solved]" to the subject line if your problem has been solved.
Apache OpenOffice 4-dev on Xubuntu 14.04
User avatar
dooteo
Posts: 7
Joined: Thu Jan 13, 2011 12:30 pm

Re: JAVA- Registering a context menu interceptor in addon.

Post by dooteo »

Hi hanya,

Are you sure that it works? I try to modify my own little extension with your advices but it does not work.

So I create a new project (in NetBeans) just with your code (and I add some lines in MyContextMenuInterceptor to create a submenu in context menu, and context menu works!), but when frame is changed from normal to preview and back to normal again (COMPONENT_REATTACHED) context menu does not work.

By the other hand, jobs.xcu OnViewCreated works fine :)

Thanks and Best Regards
Attachments
ExampleJobs_modified_src.tar.gz
(3.67 KiB) Downloaded 146 times
OOo 3.2 Debian GNU/Linux
hanya
Volunteer
Posts: 885
Joined: Fri Nov 23, 2007 9:27 am
Location: Japan

Re: JAVA- Registering a context menu interceptor in addon.

Post by hanya »

dooteo wrote:Are you sure that it works? I try to modify my own little extension with your advices but it does not work.
I tried to check it and it worked on 3.3.0 but it did not work on 3.2.1. Unfortunately there might be some changes between 3.2.1 and 3.3.0, I need some try to work it on 3.2.1.
Please, edit this thread's initial post and add "[Solved]" to the subject line if your problem has been solved.
Apache OpenOffice 4-dev on Xubuntu 14.04
hanya
Volunteer
Posts: 885
Joined: Fri Nov 23, 2007 9:27 am
Location: Japan

Re: JAVA- Registering a context menu interceptor in addon.

Post by hanya »

I made fixed one.
ExampleJob-src.zip
Fixed for 3.2.x.
(27.72 KiB) Downloaded 277 times
Please, edit this thread's initial post and add "[Solved]" to the subject line if your problem has been solved.
Apache OpenOffice 4-dev on Xubuntu 14.04
User avatar
dooteo
Posts: 7
Joined: Thu Jan 13, 2011 12:30 pm

Re: JAVA- Registering a context menu interceptor in addon.

Post by dooteo »

Meanwhile, I downloaded OOo 330 on Windows system, but unfortunately when I was trying to add your 1rst ExampleJobs.oxt, it claims 'could not create java implementation loader' (even Java was installed).

Did you know something about that?
OOo 3.2 Debian GNU/Linux
hanya
Volunteer
Posts: 885
Joined: Fri Nov 23, 2007 9:27 am
Location: Japan

Re: JAVA- Registering a context menu interceptor in addon.

Post by hanya »

dooteo wrote:Did you know something about that?
It can be installed on my Windows environment. And the error you have met is caused by the office or your system including Java.
Please, edit this thread's initial post and add "[Solved]" to the subject line if your problem has been solved.
Apache OpenOffice 4-dev on Xubuntu 14.04
Post Reply