Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/monodevelop.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Krüger <mkrueger@novell.com>2010-04-23 17:23:56 +0400
committerMike Krüger <mkrueger@novell.com>2010-04-23 17:23:56 +0400
commitb64eb3ed14823853adbcf4f108f683f1e676e010 (patch)
tree44572477c60fdd25b67845c5a422beddd2a7c0a8 /main/src/core/MonoDevelop.Ide/MonoDevelop.Components
parent50702a45715deb37035e2568f75a7e88886decc1 (diff)
* Makefile.am:
* gtk-gui/gui.stetic: * MonoDevelop.Ide.csproj: * MonoDevelop.Ide.addin.xml: * MonoDevelop.Ide.NavigateToDialog: * MonoDevelop.Components/ListView.cs: * MonoDevelop.Ide.Gui.Dialogs/GoToDialog.cs: * MonoDevelop.Ide.Commands/SearchCommands.cs: * gtk-gui/MonoDevelop.Ide.Gui.Dialogs.GoToDialog.cs: * MonoDevelop.Ide.NavigateToDialog/NavigateToDialog.cs: * MonoDevelop.Ide.NavigateToDialog/NavigateToCommand.cs: * gtk-gui/MonoDevelop.Ide.NavigateToDialog.NavigateToDialog.cs: Worked on go to dialog. (go to file/type are unaffected in function - only the gui changed). Added 'Navigate To' command which allows to navigate to any file/type/member. svn path=/trunk/monodevelop/; revision=156006
Diffstat (limited to 'main/src/core/MonoDevelop.Ide/MonoDevelop.Components')
-rw-r--r--main/src/core/MonoDevelop.Ide/MonoDevelop.Components/ListView.cs12
1 files changed, 7 insertions, 5 deletions
diff --git a/main/src/core/MonoDevelop.Ide/MonoDevelop.Components/ListView.cs b/main/src/core/MonoDevelop.Ide/MonoDevelop.Components/ListView.cs
index e756cb0162..54b592bc3a 100644
--- a/main/src/core/MonoDevelop.Ide/MonoDevelop.Components/ListView.cs
+++ b/main/src/core/MonoDevelop.Ide/MonoDevelop.Components/ListView.cs
@@ -507,7 +507,8 @@ namespace MonoDevelop.Components
int n = 0;
while (ypos < winHeight - margin && (page + n) < RowCount)
{
- bool hasMarkup = SetLayoutText (page + n);
+ bool isSelected = selectedRows.Contains (page + n);
+ bool hasMarkup = SetLayoutText (page + n, isSelected);
Gdk.Pixbuf icon = dataProvider.GetIcon (page + n);
int iconHeight = icon != null? icon.Height : IconWidth;
@@ -518,7 +519,7 @@ namespace MonoDevelop.Components
typos = he < rowHeight ? ypos + (rowHeight - he) / 2 : ypos;
iypos = iconHeight < rowHeight ? ypos + (rowHeight - iconHeight) / 2 : ypos;
- if (selectedRows.Contains (page + n)) {
+ if (isSelected) {
if (!disableSelection) {
this.GdkWindow.DrawRectangle (this.Style.BaseGC (StateType.Selected),
true, margin, ypos, lineWidth, he + padding);
@@ -557,11 +558,11 @@ namespace MonoDevelop.Components
}
}
- bool SetLayoutText (int n)
+ bool SetLayoutText (int n, bool isSelected)
{
bool hasMarkup = dataProvider.UseMarkup (n);
- string text = dataProvider.GetText (n);
+ string text = isSelected ? dataProvider.GetSelectedText (n) : dataProvider.GetText (n);
if (hasMarkup)
layout.SetMarkup (text ?? "&lt;null&gt;");
else
@@ -625,7 +626,7 @@ namespace MonoDevelop.Components
if (dataProvider != null) {
int maxr = Math.Min (page + visibleRows, dataProvider.ItemCount);
for (int n=page; n<maxr; n++) {
- SetLayoutText (n);
+ SetLayoutText (n, false);
int rh, rw;
layout.GetPixelSize (out rw, out rh);
rw += (margin + padding) * 2 + IconWidth + ColumnGap;
@@ -653,6 +654,7 @@ namespace MonoDevelop.Components
{
int ItemCount { get; }
string GetText (int n);
+ string GetSelectedText (int n);
bool UseMarkup (int n);
Gdk.Pixbuf GetIcon (int n);
}