This is a migrated thread and some comments may be shown as answers.

[Solved] Contextmenu

3 Answers 202 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
icebits
Top achievements
Rank 1
icebits asked on 08 Jan 2008, 07:00 AM
I want to post using support ticket, but treeview yet included.

How to let contextmenu color back to normal after clicked on contextmenu? The color of contextmenu item will have the same color with hover color. I am not using any skin, so the color will be: -

font = black and background = white for normal
font = white and background = black for hover/after clicked

I am doing in client-side using ajax, not server-side.

Thank you.

3 Answers, 1 is accepted

Sort by
0
Erjan Gavalji
Telerik team
answered on 08 Jan 2008, 05:21 PM
Hi icebits,

I'm not sure if I understood you correctly, but if what you need is mark a clicked menu item, the attached page will help you with the task.

What it does is change the style of the clicked items' text element by attaching to the OnClientContextMenuItemClicked event of RadTreeView.

Let me know if that helps.

Regards,
Erjan Gavalji
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
icebits
Top achievements
Rank 1
answered on 09 Jan 2008, 01:03 AM
Sorry, my explaination was confusing. I just want the context menu not to be highligted/selected after a click on it, can it be done with and without skin? Current behaviour is that the context menu will be highlighted with hover css style after user click/select on it.

I attached the screenshot for you. You have to download from free host as i can't attached here. Download.
0
Erjan Gavalji
Telerik team
answered on 09 Jan 2008, 12:22 PM
Hi icebits,

Changing the appearance of RadContextMenu items is possible both when using a skin and not using a skin.

When not using a skin the specific is that you need to set style definitions for each element in the RadContextMenu HTML element hierarchy, which can become very hard.

Modifying the styles of a skinned RadContextMenu is the easier approach, where you would need to have a simple <style> declaration in your page like:

<style type="text/css">
 .RadMenu_[SKIN_NAME] .rmGroup .rmLink:hover,
 .RadMenu_[SKIN_NAME] .rmGroup .rmFocused,
 .RadMenu_[SKIN_NAME] .rmGroup .rmExpanded
 {
  background-color: #ffffff;
  color: #000000;
 }
</style>


Please, find a page demonstrating the above suggestion.

I hope this helps.

Kind regards,
Erjan Gavalji
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
Tags
TreeView
Asked by
icebits
Top achievements
Rank 1
Answers by
Erjan Gavalji
Telerik team
icebits
Top achievements
Rank 1
Share this question
or