Example #1
0
        private void _generateToolTip()
        {
            string toolTip = "File not found.";

            if (Browser.BrowseMode == PathBrowser.BrowseModeType.Folder)
            {
                if (Filepath != null && _metaGrf != null && Directory.Exists(Filepath))
                {
                    toolTip = Filepath;
                }

                if (Filepath != null && !IOHelper.IsSystemFile(Filepath))
                {
                    toolTip = Filepath;
                }
            }
            else
            {
                if (Filepath != null && _metaGrf != null && _metaGrf.GetData(Filepath) != null)
                {
                    if (File.Exists(Filepath))
                    {
                        toolTip = Filepath;
                    }
                    else
                    {
                        TkPath path = _metaGrf.FindTkPath(Filepath);

                        if (String.IsNullOrEmpty(path.RelativePath))
                        {
                            toolTip = path.FilePath;
                        }
                        else
                        {
                            toolTip = path.FilePath + "\r\n" + path.RelativePath;
                        }
                    }
                }
            }

            _toolTip.Content = toolTip;
        }