File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Right Click Option in JtextPane

 
Siddique Ansari
Greenhorn
Posts: 21
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I want to get options "Add to Name".. etc.. and am getting that.. but my problem is when I right click first then it show all MenuItems once, When I right click Again it shows all the options twice, when I right click again then it shows thrice. Tell me whats the problem?


 
Piet Souris
Ranch Hand
Posts: 1099
16
  • 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Siddique,

well, have a look at line 17. You add an item to a menu. But suppose that item was already present in that menu (say, from a former right mouse click)?

Greetings,
Piet
 
Campbell Ritchie
Sheriff
Pie
Posts: 47293
52
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
And welcome to the Ranch
 
Siddique Ansari
Greenhorn
Posts: 21
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
THANKS....
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic