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

github.com/xamarin/macdoc.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeremie Laval <jeremie.laval@gmail.com>2013-03-12 17:48:39 +0400
committerJeremie Laval <jeremie.laval@gmail.com>2013-03-12 17:48:39 +0400
commitffc9bf8e51b7c935a55d811b421dccac6357bcf6 (patch)
tree2807f4e0722d0e90368e07ee39738639cbd75b73
parenta5654a9b1cbfd0c7f74d121541effd68f8b45333 (diff)
[macdoc] Update to use non-deprecated API
-rw-r--r--AppDelegate.cs2
-rw-r--r--MonodocDataSources.cs8
-rw-r--r--MyDocument.cs4
3 files changed, 7 insertions, 7 deletions
diff --git a/AppDelegate.cs b/AppDelegate.cs
index be81626..9b88c6d 100644
--- a/AppDelegate.cs
+++ b/AppDelegate.cs
@@ -132,7 +132,7 @@ namespace macdoc
}).ContinueWith (t => Logger.LogError ("Error while creating indexes", t.Exception), TaskContinuationOptions.OnlyOnFaulted);
// Check if there is a MonoTouch/MonoMac documentation installed and launch accordingly
- var products = Root.HelpSources.Cast<HelpSource> ().Where (hs => hs != null && hs.Name != null).ToProducts ();
+ var products = Root.HelpSources.Where (hs => hs != null && hs.Name != null).ToProducts ();
if (products.Where (p => File.Exists (ProductUtils.GetMergeToolForProduct (p))).Any ()) {
Task.Factory.StartNew (() => {
return products.ToDictionary (p => p,
diff --git a/MonodocDataSources.cs b/MonodocDataSources.cs
index d3507ee..d5fc8ed 100644
--- a/MonodocDataSources.cs
+++ b/MonodocDataSources.cs
@@ -64,7 +64,7 @@ namespace macdoc
public override NSObject GetChild (NSOutlineView outlineView, int index, NSObject item)
{
WrapNode wrap;
- Node n = (Node) (item == null ? Root.RootNode : (Node) GetNode (item)).Nodes [index];
+ Node n = (Node) (item == null ? Root.RootNode : (Node) GetNode (item)).ChildNodes [index];
if (nodeToWrapper.ContainsKey (n))
return nodeToWrapper [n];
@@ -77,14 +77,14 @@ namespace macdoc
{
if (item == null)
return true;
- return GetNode (item).Nodes.Count > 0;
+ return GetNode (item).ChildNodes.Count > 0;
}
public override int GetChildrenCount (NSOutlineView outlineView, NSObject item)
{
if (item == null)
- return Root.RootNode.Nodes.Count;
- return GetNode (item).Nodes.Count;
+ return Root.RootNode.ChildNodes.Count;
+ return GetNode (item).ChildNodes.Count;
}
public override NSObject GetObjectValue (NSOutlineView outlineView, NSTableColumn tableColumn, NSObject item)
diff --git a/MyDocument.cs b/MyDocument.cs
index bc39c4f..81ea333 100644
--- a/MyDocument.cs
+++ b/MyDocument.cs
@@ -503,8 +503,8 @@ namespace macdoc
outlineView.ExpandItem (item);
// Focus the last child, then this child to ensure we show as much as possible
- if (n.Nodes.Count > 0)
- ScrollToVisible ((Node) n.Nodes [n.Nodes.Count-1]);
+ if (n.ChildNodes.Count > 0)
+ ScrollToVisible ((Node) n.ChildNodes [n.ChildNodes.Count-1]);
var row = ScrollToVisible (n);
ignoreSelect = true;
if (row > 0)