mirror of
https://github.com/PredatH0r/ChanSort.git
synced 2026-07-01 00:20:02 +02:00
- allow Pr#0 for analog channels
- added loader for Toshiba *.db files (saving not yet implemented)
This commit is contained in:
2
.gitignore
vendored
2
.gitignore
vendored
@@ -27,3 +27,5 @@ obj/
|
||||
[Rr]elease*/
|
||||
_ReSharper*/
|
||||
[Tt]est[Rr]esult*
|
||||
DLL/SQLite.Designer.dll
|
||||
DLL/SQLite.Designer.xml
|
||||
|
||||
@@ -25,7 +25,7 @@ namespace ChanSort.Api
|
||||
this.warnings.Remove(0, this.warnings.Length);
|
||||
|
||||
foreach (var channel in this.channelList.Channels)
|
||||
channel.NewProgramNr = 0;
|
||||
channel.NewProgramNr = -1;
|
||||
|
||||
using (var stream = new StreamReader(fileName, System.Text.Encoding.Default))
|
||||
{
|
||||
@@ -80,7 +80,7 @@ namespace ChanSort.Api
|
||||
|
||||
foreach(var channel in channels)
|
||||
{
|
||||
if (channel.NewProgramNr != 0)
|
||||
if (channel.NewProgramNr != -1)
|
||||
continue;
|
||||
++found;
|
||||
if (found > 1)
|
||||
|
||||
@@ -74,7 +74,7 @@ namespace ChanSort.Api
|
||||
return;
|
||||
|
||||
IEnumerable<ChannelInfo> channels = FindChannels(channelList, name, uid);
|
||||
var channel = channels == null ? null : channels.FirstOrDefault(c => c.NewProgramNr == 0);
|
||||
var channel = channels == null ? null : channels.FirstOrDefault(c => c.NewProgramNr == -1);
|
||||
if (channel != null)
|
||||
{
|
||||
channel.NewProgramNr = programNr;
|
||||
@@ -138,7 +138,7 @@ namespace ChanSort.Api
|
||||
if (!this.clearedLists.Contains(channelList))
|
||||
{
|
||||
foreach (var channel in channelList.Channels)
|
||||
channel.NewProgramNr = 0;
|
||||
channel.NewProgramNr = -1;
|
||||
this.clearedLists.Add(channelList);
|
||||
}
|
||||
return channelList;
|
||||
@@ -206,7 +206,7 @@ namespace ChanSort.Api
|
||||
{
|
||||
foreach (var channelList in dataRoot.ChannelLists)
|
||||
{
|
||||
foreach (var channel in channelList.Channels.Where(ch => ch.NewProgramNr != 0).OrderBy(ch => ch.NewProgramNr))
|
||||
foreach (var channel in channelList.Channels.Where(ch => ch.NewProgramNr != -1).OrderBy(ch => ch.NewProgramNr))
|
||||
{
|
||||
string line = string.Format("{0},{1},{2},{3},\"{4}\",{5},{6}",
|
||||
"", // past: channel.RecordIndex,
|
||||
|
||||
@@ -9,114 +9,11 @@ namespace ChanSort.Api
|
||||
public ChannelList ChannelList;
|
||||
private UnsortedChannelMode unsortedChannelMode;
|
||||
|
||||
#if false
|
||||
#region LoadDvbViewerFiles()
|
||||
private void LoadDvbViewerFiles()
|
||||
{
|
||||
List<string> fileList;
|
||||
Dictionary<string, string> satPosition;
|
||||
if (!LoadSatMappingFile(out satPosition, out fileList))
|
||||
return;
|
||||
|
||||
foreach (var file in fileList)
|
||||
{
|
||||
try
|
||||
{
|
||||
string fullPath = Path.IsPathRooted(file)
|
||||
? file
|
||||
: Path.Combine(Path.GetDirectoryName(Application.ExecutablePath), file);
|
||||
this.LoadDvbViewerChannelFile(fullPath, satPosition);
|
||||
}
|
||||
catch
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region LoadSatMappingFile()
|
||||
private static bool LoadSatMappingFile(out Dictionary<string, string> satPosition, out List<string> fileList)
|
||||
{
|
||||
satPosition = null;
|
||||
fileList = null;
|
||||
string satMappingFile = Path.Combine(Path.GetDirectoryName(Application.ExecutablePath), "sat-mapping.ini");
|
||||
if (!File.Exists(satMappingFile))
|
||||
return false;
|
||||
|
||||
fileList = new List<string>();
|
||||
satPosition = new Dictionary<string, string>();
|
||||
string section = null;
|
||||
using (var stream = new StreamReader(satMappingFile, Encoding.UTF8))
|
||||
{
|
||||
string line;
|
||||
while ((line = stream.ReadLine()) != null)
|
||||
{
|
||||
line = line.Trim();
|
||||
if (line.Length == 0 || line.StartsWith(";"))
|
||||
continue;
|
||||
if (line.StartsWith("[") && line.EndsWith("]"))
|
||||
{
|
||||
section = line;
|
||||
continue;
|
||||
}
|
||||
if (section == "[Satellites]")
|
||||
{
|
||||
var parts = line.Split(new[] { '=' }, 2);
|
||||
if (parts.Length == 2)
|
||||
satPosition[parts[0].ToLower()] = parts[1].ToUpper();
|
||||
}
|
||||
else if (section == "[DvbViewerChannelFiles]")
|
||||
{
|
||||
fileList.Set(line);
|
||||
}
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region LoadDvbViewerChannelFile()
|
||||
private void LoadDvbViewerChannelFile(string file, IDictionary<string, string> satPosition)
|
||||
{
|
||||
string[] unencrypted = { "18", "19", "26", "146", "154" };
|
||||
|
||||
using (var stream = new StreamReader(file, Encoding.Default))
|
||||
{
|
||||
string line;
|
||||
bool first = true;
|
||||
while ((line = stream.ReadLine()) != null)
|
||||
{
|
||||
if (first)
|
||||
{
|
||||
first = false;
|
||||
continue;
|
||||
}
|
||||
var col = line.Split(new[] { '\t' });
|
||||
if (col.Length < 21)
|
||||
continue;
|
||||
|
||||
string satId;
|
||||
if (!satPosition.TryGetValue(col[0].ToLower(), out satId))
|
||||
continue;
|
||||
|
||||
StringBuilder uid = new StringBuilder();
|
||||
uid.Append("S").Append(satId).Append("-").Append(col[20]).Append("-").Append(col[18]).Append("-").Append(col[17]);
|
||||
|
||||
ChannelInfo channel;
|
||||
if (!TvChannelByUid.TryGetValue(uid.ToString(), out channel))
|
||||
continue;
|
||||
channel.Encrypted = Array.IndexOf(unencrypted, col[19]) < 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
#endif
|
||||
|
||||
#region AddChannels()
|
||||
|
||||
public ChannelInfo AddChannels(IList<ChannelInfo> channels)
|
||||
{
|
||||
int count = channels.Count(channel => channel.NewProgramNr == 0);
|
||||
int count = channels.Count(channel => channel.NewProgramNr == -1);
|
||||
if (count == 0) return null;
|
||||
|
||||
ChannelInfo lastInsertedChannel = null;
|
||||
@@ -124,20 +21,17 @@ namespace ChanSort.Api
|
||||
int relativeChannelNumber = 0;
|
||||
foreach(var channel in this.ChannelList.Channels.Where(c => c.NewProgramNr>=progNr).OrderBy(c=>c.NewProgramNr))
|
||||
{
|
||||
//if (channel.NewProgramNr != 0 && channel.NewProgramNr >= progNr)
|
||||
int gap = count - (channel.NewProgramNr - progNr - relativeChannelNumber);
|
||||
if (gap > 0)
|
||||
{
|
||||
int gap = count - (channel.NewProgramNr - progNr - relativeChannelNumber);
|
||||
if (gap > 0)
|
||||
{
|
||||
channel.NewProgramNr += gap;
|
||||
++relativeChannelNumber;
|
||||
}
|
||||
channel.NewProgramNr += gap;
|
||||
++relativeChannelNumber;
|
||||
}
|
||||
}
|
||||
|
||||
foreach (var channel in channels)
|
||||
{
|
||||
if (channel.NewProgramNr != 0)
|
||||
if (channel.NewProgramNr != -1)
|
||||
{
|
||||
// TODO notify user
|
||||
continue;
|
||||
@@ -160,10 +54,10 @@ namespace ChanSort.Api
|
||||
if (channels.Count == 0) return;
|
||||
|
||||
this.ChannelList.InsertProgramNumber = channels[0].NewProgramNr;
|
||||
var orderedChannelList = this.ChannelList.Channels.Where(c => c.NewProgramNr > 0).OrderBy(c => c.NewProgramNr);
|
||||
var orderedChannelList = this.ChannelList.Channels.Where(c => c.NewProgramNr != -1).OrderBy(c => c.NewProgramNr);
|
||||
foreach (var channel in channels)
|
||||
{
|
||||
if (channel.NewProgramNr == 0)
|
||||
if (channel.NewProgramNr == -1)
|
||||
continue;
|
||||
if (closeGap)
|
||||
{
|
||||
@@ -179,7 +73,7 @@ namespace ChanSort.Api
|
||||
}
|
||||
}
|
||||
}
|
||||
channel.NewProgramNr = 0;
|
||||
channel.NewProgramNr = -1;
|
||||
}
|
||||
|
||||
this.DataRoot.NeedsSaving = true;
|
||||
@@ -193,7 +87,7 @@ namespace ChanSort.Api
|
||||
{
|
||||
if (channels.Count == 0)
|
||||
return;
|
||||
if (up && channels[0].NewProgramNr < 2)
|
||||
if (up && channels[0].NewProgramNr <= this.ChannelList.FirstProgramNumber)
|
||||
return;
|
||||
|
||||
int delta = (up ? - 1 : +1);
|
||||
@@ -237,7 +131,7 @@ namespace ChanSort.Api
|
||||
{
|
||||
foreach (var channel in channels)
|
||||
{
|
||||
if (slot != 0)
|
||||
if (slot != -1)
|
||||
{
|
||||
var others = this.ChannelList.GetChannelByNewProgNr(slot);
|
||||
foreach (var other in others)
|
||||
@@ -295,7 +189,7 @@ namespace ChanSort.Api
|
||||
if (appChannel.RecordIndex < 0)
|
||||
continue;
|
||||
|
||||
if (appChannel.NewProgramNr <= 0 && mode == UnsortedChannelMode.MarkDeleted)
|
||||
if (appChannel.NewProgramNr == -1 && mode == UnsortedChannelMode.MarkDeleted)
|
||||
continue;
|
||||
|
||||
int progNr = GetNewProgramNr(appChannel, ref maxProgNr);
|
||||
@@ -308,7 +202,7 @@ namespace ChanSort.Api
|
||||
private string ChanSortCriteria(ChannelInfo channel)
|
||||
{
|
||||
// explicitly sorted
|
||||
if (channel.NewProgramNr != 0)
|
||||
if (channel.NewProgramNr != -1)
|
||||
return channel.NewProgramNr.ToString("d4");
|
||||
|
||||
// eventually hide unsorted channels
|
||||
@@ -334,9 +228,9 @@ namespace ChanSort.Api
|
||||
int prNr = appChannel.NewProgramNr;
|
||||
if (prNr > maxPrNr)
|
||||
maxPrNr = prNr;
|
||||
if (prNr == 0)
|
||||
if (prNr == -1)
|
||||
{
|
||||
if (appChannel.OldProgramNr != 0 && this.unsortedChannelMode != UnsortedChannelMode.MarkDeleted)
|
||||
if (appChannel.OldProgramNr != -1 && this.unsortedChannelMode != UnsortedChannelMode.MarkDeleted)
|
||||
prNr = ++maxPrNr;
|
||||
}
|
||||
return prNr;
|
||||
|
||||
@@ -12,7 +12,7 @@ namespace ChanSort.Api
|
||||
public readonly List<ChannelInfo> Duplicates = new List<ChannelInfo>();
|
||||
|
||||
public virtual bool IsDeleted { get; set; }
|
||||
public SignalSource SignalSource { get; protected set; }
|
||||
public SignalSource SignalSource { get; set; }
|
||||
public int RecordIndex { get; set; }
|
||||
public int RecordOrder { get; set; }
|
||||
public int OldProgramNr { get; set; }
|
||||
@@ -43,7 +43,8 @@ namespace ChanSort.Api
|
||||
|
||||
#region ctor()
|
||||
protected ChannelInfo()
|
||||
{
|
||||
{
|
||||
this.NewProgramNr = -1;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -54,6 +55,7 @@ namespace ChanSort.Api
|
||||
this.SignalSource = source;
|
||||
this.RecordIndex = index;
|
||||
this.RecordOrder = index;
|
||||
this.NewProgramNr = -1;
|
||||
this.OldProgramNr = oldProgNr;
|
||||
this.Name = name;
|
||||
this.Encrypted = null;
|
||||
@@ -66,6 +68,7 @@ namespace ChanSort.Api
|
||||
{
|
||||
this.SignalSource = source;
|
||||
this.Uid = uid;
|
||||
this.OldProgramNr = -1;
|
||||
this.NewProgramNr = newProgNr;
|
||||
this.Name = name;
|
||||
this.Encrypted = null;
|
||||
|
||||
@@ -19,6 +19,7 @@ namespace ChanSort.Api
|
||||
{
|
||||
this.source = source;
|
||||
this.ShortCaption = caption;
|
||||
this.FirstProgramNumber = (source & SignalSource.Digital) != 0 ? 1 : 0;
|
||||
}
|
||||
|
||||
public string ShortCaption { get; private set; }
|
||||
@@ -34,7 +35,7 @@ namespace ChanSort.Api
|
||||
get
|
||||
{
|
||||
string cap = this.ShortCaption;
|
||||
int validChannelCount = this.Channels.Count(ch => ch.OldProgramNr != 0);
|
||||
int validChannelCount = this.Channels.Count(ch => ch.OldProgramNr != -1);
|
||||
return cap + " (" + validChannelCount + ")";
|
||||
}
|
||||
}
|
||||
@@ -44,10 +45,12 @@ namespace ChanSort.Api
|
||||
public int InsertProgramNumber
|
||||
{
|
||||
get { return this.Count == 0 ? 1 : this.insertProgramNr; }
|
||||
set { this.insertProgramNr = Math.Max(1, value); }
|
||||
set { this.insertProgramNr = Math.Max(this.FirstProgramNumber, value); }
|
||||
}
|
||||
#endregion
|
||||
|
||||
public int FirstProgramNumber { get; set; }
|
||||
|
||||
#region AddChannel()
|
||||
public string AddChannel(ChannelInfo ci)
|
||||
{
|
||||
@@ -63,7 +66,7 @@ namespace ChanSort.Api
|
||||
|
||||
string warning2 = null;
|
||||
bool isDupeProgNr = false;
|
||||
if (ci.OldProgramNr != 0)
|
||||
if (ci.OldProgramNr != -1)
|
||||
{
|
||||
ChannelInfo other;
|
||||
this.channelByProgNr.TryGetValue(ci.OldProgramNr, out other);
|
||||
|
||||
93
ChanSort.Loader.DbFile/ChanSort.Loader.DbFile.csproj
Normal file
93
ChanSort.Loader.DbFile/ChanSort.Loader.DbFile.csproj
Normal file
@@ -0,0 +1,93 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProductVersion>8.0.30703</ProductVersion>
|
||||
<SchemaVersion>2.0</SchemaVersion>
|
||||
<ProjectGuid>{F6F02792-07F1-48D5-9AF3-F945CA5E3931}</ProjectGuid>
|
||||
<OutputType>Library</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>ChanSort.Loader.DbFile</RootNamespace>
|
||||
<AssemblyName>ChanSort.Loader.DbFile</AssemblyName>
|
||||
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
|
||||
<TargetFrameworkProfile>
|
||||
</TargetFrameworkProfile>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>..\Debug\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<PlatformTarget>x86</PlatformTarget>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x86'">
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<OutputPath>..\Debug\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<DebugType>full</DebugType>
|
||||
<PlatformTarget>x86</PlatformTarget>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<CodeAnalysisIgnoreBuiltInRuleSets>false</CodeAnalysisIgnoreBuiltInRuleSets>
|
||||
<CodeAnalysisIgnoreBuiltInRules>false</CodeAnalysisIgnoreBuiltInRules>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x86'">
|
||||
<OutputPath>bin\x86\Release\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<Optimize>true</Optimize>
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<PlatformTarget>x86</PlatformTarget>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<CodeAnalysisIgnoreBuiltInRuleSets>false</CodeAnalysisIgnoreBuiltInRuleSets>
|
||||
<CodeAnalysisIgnoreBuiltInRules>false</CodeAnalysisIgnoreBuiltInRules>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="SQLite.Designer">
|
||||
<HintPath>..\DLL\SQLite.Designer.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Data.SQLite">
|
||||
<HintPath>..\DLL\System.Data.SQLite.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.Drawing" />
|
||||
<Reference Include="System.Windows.Forms" />
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<Compile Include="DbSerializer.cs" />
|
||||
<Compile Include="DbSerializerPlugin.cs" />
|
||||
<Service Include="{94E38DFF-614B-4cbd-B67C-F211BB35CE8B}" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\ChanSort.Api\ChanSort.Api.csproj">
|
||||
<Project>{DCCFFA08-472B-4D17-BB90-8F513FC01392}</Project>
|
||||
<Name>ChanSort.Api</Name>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||
Other similar extension points exist, see Microsoft.Common.targets.
|
||||
<Target Name="BeforeBuild">
|
||||
</Target>
|
||||
<Target Name="AfterBuild">
|
||||
</Target>
|
||||
-->
|
||||
</Project>
|
||||
276
ChanSort.Loader.DbFile/DbSerializer.cs
Normal file
276
ChanSort.Loader.DbFile/DbSerializer.cs
Normal file
@@ -0,0 +1,276 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Data.SQLite;
|
||||
using System.IO;
|
||||
using System.Text;
|
||||
using ChanSort.Api;
|
||||
|
||||
namespace ChanSort.Loader.DbFile
|
||||
{
|
||||
class DbSerializer : SerializerBase
|
||||
{
|
||||
private const int BITS_InUse = 0x10000;
|
||||
private readonly ChannelList atvChannels = new ChannelList(SignalSource.AnalogCT | SignalSource.TvAndRadio, "Analog");
|
||||
private readonly ChannelList dtvChannels = new ChannelList(SignalSource.DvbCT | SignalSource.TvAndRadio, "DVB-C/T");
|
||||
private readonly ChannelList satChannels = new ChannelList(SignalSource.DvbS | SignalSource.TvAndRadio, "Satellite");
|
||||
|
||||
#region ctor()
|
||||
public DbSerializer(string inputFile) : base(inputFile)
|
||||
{
|
||||
this.Features.ChannelNameEdit = true;
|
||||
|
||||
this.DataRoot.AddChannelList(this.atvChannels);
|
||||
this.DataRoot.AddChannelList(this.dtvChannels);
|
||||
this.DataRoot.AddChannelList(this.satChannels);
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region DisplayName
|
||||
public override string DisplayName { get { return "Toshiba *.db Loader"; } }
|
||||
#endregion
|
||||
|
||||
|
||||
#region Load()
|
||||
public override void Load()
|
||||
{
|
||||
string sysDataConnString = "Data Source=" + Path.GetDirectoryName(Path.GetDirectoryName(this.FileName)) +
|
||||
"\\dvb_type001\\dvbSysData.db";
|
||||
using (var sysDataConn = new SQLiteConnection(sysDataConnString))
|
||||
{
|
||||
sysDataConn.Open();
|
||||
using (var cmd = sysDataConn.CreateCommand())
|
||||
{
|
||||
this.ReadSatellites(cmd);
|
||||
this.ReadTransponders(cmd);
|
||||
}
|
||||
}
|
||||
|
||||
string channelConnString = "Data Source=" + this.FileName;
|
||||
using (var channelConn = new SQLiteConnection(channelConnString))
|
||||
{
|
||||
channelConn.Open();
|
||||
using (var cmd = channelConn.CreateCommand())
|
||||
{
|
||||
this.ReadAnalogChannels(cmd);
|
||||
this.ReadDtvChannels(cmd);
|
||||
this.ReadSatChannels(cmd);
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region ReadSatellites()
|
||||
private void ReadSatellites(SQLiteCommand cmd)
|
||||
{
|
||||
cmd.CommandText = "select distinct satellite_id, satellite_name, orbital_position, west_east_flag from satellite";
|
||||
using (var r = cmd.ExecuteReader())
|
||||
{
|
||||
while (r.Read())
|
||||
{
|
||||
Satellite sat = new Satellite(r.GetInt32(0));
|
||||
int pos = r.GetInt32(2);
|
||||
sat.OrbitalPosition = string.Format("{0}.{1}{2}", pos / 10, pos % 10, r.GetInt32(3) == 1 ? "E" : "W");
|
||||
sat.Name = r.GetString(1) + " " + sat.OrbitalPosition;
|
||||
this.DataRoot.AddSatellite(sat);
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region ReadTransponders()
|
||||
private void ReadTransponders(SQLiteCommand cmd)
|
||||
{
|
||||
cmd.CommandText = "select satellite_id, frequency, polarization, symbol_rate, transponder_number from satellite";
|
||||
using (var r = cmd.ExecuteReader())
|
||||
{
|
||||
while (r.Read())
|
||||
{
|
||||
int satId = r.GetInt32(0);
|
||||
int freq = r.GetInt32(1);
|
||||
int id = satId * 1000000 + freq / 1000;
|
||||
if (this.DataRoot.Transponder.TryGet(id) != null)
|
||||
continue;
|
||||
Transponder tp = new Transponder(id);
|
||||
tp.FrequencyInMhz = (decimal)freq / 1000;
|
||||
tp.Number = r.GetInt32(4);
|
||||
tp.Polarity = r.GetInt32(2) == 0 ? 'H' : 'V';
|
||||
tp.Satellite = this.DataRoot.Satellites.TryGet(satId);
|
||||
tp.SymbolRate = r.GetInt32(3) / 1000;
|
||||
this.DataRoot.AddTransponder(tp.Satellite, tp);
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
|
||||
#region ReadAnalogChannels()
|
||||
private void ReadAnalogChannels(SQLiteCommand cmd)
|
||||
{
|
||||
string[] fieldNames = {"channel_handle", "channel_number", "list_bits", "channel_label", "frequency"};
|
||||
var sql = this.GetQuery("EuroATVChanList", fieldNames);
|
||||
var fields = this.GetFieldMap(fieldNames);
|
||||
|
||||
cmd.CommandText = sql;
|
||||
using (var r = cmd.ExecuteReader())
|
||||
{
|
||||
while (r.Read())
|
||||
ReadAnalogChannel(r, fields);
|
||||
}
|
||||
}
|
||||
|
||||
private void ReadAnalogChannel(SQLiteDataReader r, IDictionary<string, int> field)
|
||||
{
|
||||
var bits = r.GetInt32(field["list_bits"]);
|
||||
if ((bits & BITS_InUse) == 0)
|
||||
return;
|
||||
|
||||
ChannelInfo channel = new ChannelInfo(SignalSource.Analog|SignalSource.Tv,
|
||||
r.GetInt32(field["channel_handle"]),
|
||||
r.GetInt32(field["channel_number"]),
|
||||
r.GetString(field["channel_label"]));
|
||||
|
||||
channel.FreqInMhz = (decimal) r.GetInt32(field["frequency"])/1000000;
|
||||
|
||||
this.DataRoot.AddChannel(this.atvChannels, channel);
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region ReadDtvChannels()
|
||||
private void ReadDtvChannels(SQLiteCommand cmd)
|
||||
{
|
||||
this.ReadDigitalChannels(cmd, "EuroDTVChanList", SignalSource.DvbCT, this.dtvChannels);
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region ReadSatChannels()
|
||||
private void ReadSatChannels(SQLiteCommand cmd)
|
||||
{
|
||||
this.ReadDigitalChannels(cmd, "EuroSATChanList", SignalSource.DvbS, this.satChannels);
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region ReadDigitalChannels()
|
||||
private void ReadDigitalChannels(SQLiteCommand cmd, string table, SignalSource signalSource, ChannelList channels)
|
||||
{
|
||||
string[] fieldNames = { "channel_handle", "channel_number", "list_bits", "channel_label", "frequency",
|
||||
"dvb_service_type", "onid", "tsid", "sid", "sat_id", "channel_order" };
|
||||
var sql = this.GetQuery(table, fieldNames);
|
||||
var fields = this.GetFieldMap(fieldNames);
|
||||
|
||||
cmd.CommandText = sql;
|
||||
using (var r = cmd.ExecuteReader())
|
||||
{
|
||||
while (r.Read())
|
||||
ReadDigitalChannel(r, fields, signalSource, channels);
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region ReadDigitalChannel()
|
||||
private void ReadDigitalChannel(SQLiteDataReader r, IDictionary<string, int> field, SignalSource signalSource, ChannelList channels)
|
||||
{
|
||||
var bits = r.GetInt32(field["list_bits"]);
|
||||
if ((bits & BITS_InUse) == 0)
|
||||
return;
|
||||
|
||||
var name = r.GetString(field["channel_label"]);
|
||||
string longName, shortName;
|
||||
this.GetChannelNames(name, out longName, out shortName);
|
||||
|
||||
ChannelInfo channel = new ChannelInfo(signalSource,
|
||||
r.GetInt32(field["channel_handle"]),
|
||||
r.GetInt32(field["channel_number"]),
|
||||
longName);
|
||||
channel.ShortName = shortName;
|
||||
channel.RecordOrder = r.GetInt32(field["channel_order"]);
|
||||
channel.FreqInMhz = (decimal)r.GetInt32(field["frequency"]) / 1000;
|
||||
int serviceType = r.GetInt32(field["dvb_service_type"]);
|
||||
if (serviceType == 1 || serviceType == 25)
|
||||
channel.SignalSource |= SignalSource.Tv;
|
||||
else if (serviceType == 2)
|
||||
channel.SignalSource |= SignalSource.Radio;
|
||||
channel.ServiceType = serviceType;
|
||||
channel.OriginalNetworkId = r.GetInt32(field["onid"]);
|
||||
channel.TransportStreamId = r.GetInt32(field["tsid"]);
|
||||
channel.ServiceId = r.GetInt32(field["sid"]);
|
||||
|
||||
if ((signalSource & SignalSource.Sat) != 0)
|
||||
{
|
||||
int satId = r.GetInt32(field["sat_id"]);
|
||||
var sat = this.DataRoot.Satellites.TryGet(satId);
|
||||
if (sat != null)
|
||||
{
|
||||
channel.Satellite = sat.Name;
|
||||
channel.SatPosition = sat.OrbitalPosition;
|
||||
int tpId = satId*1000000 + (int) channel.FreqInMhz;
|
||||
var tp = this.DataRoot.Transponder.TryGet(tpId);
|
||||
if (tp != null)
|
||||
{
|
||||
channel.SymbolRate = tp.SymbolRate;
|
||||
}
|
||||
}
|
||||
}
|
||||
this.DataRoot.AddChannel(channels, channel);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region GetQuery()
|
||||
private string GetQuery(string table, string[] fieldNames)
|
||||
{
|
||||
string sql = "select ";
|
||||
for (int i = 0; i < fieldNames.Length; i++)
|
||||
{
|
||||
if (i > 0)
|
||||
sql += ",";
|
||||
sql += fieldNames[i];
|
||||
}
|
||||
sql += " from " + table;
|
||||
return sql;
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region GetFieldMap()
|
||||
private IDictionary<string, int> GetFieldMap(string[] fieldNames)
|
||||
{
|
||||
Dictionary<string, int> field = new Dictionary<string, int>();
|
||||
for (int i = 0; i < fieldNames.Length; i++)
|
||||
field[fieldNames[i]] = i;
|
||||
return field;
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region GetChannelNames()
|
||||
private void GetChannelNames(string name, out string longName, out string shortName)
|
||||
{
|
||||
StringBuilder sbLong = new StringBuilder();
|
||||
StringBuilder sbShort = new StringBuilder();
|
||||
|
||||
bool inShort = false;
|
||||
foreach (char c in name)
|
||||
{
|
||||
if (c == 0x86)
|
||||
inShort = true;
|
||||
else if (c == 0x87)
|
||||
inShort = false;
|
||||
if (c >= 0x80 && c <= 0x9F)
|
||||
continue;
|
||||
|
||||
if (inShort)
|
||||
sbShort.Append(c);
|
||||
sbLong.Append(c);
|
||||
}
|
||||
|
||||
longName = sbLong.ToString();
|
||||
shortName = sbShort.ToString();
|
||||
}
|
||||
#endregion
|
||||
|
||||
|
||||
public override void Save(string tvOutputFile, string csvOutputFile)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
15
ChanSort.Loader.DbFile/DbSerializerPlugin.cs
Normal file
15
ChanSort.Loader.DbFile/DbSerializerPlugin.cs
Normal file
@@ -0,0 +1,15 @@
|
||||
using ChanSort.Api;
|
||||
|
||||
namespace ChanSort.Loader.DbFile
|
||||
{
|
||||
public class DbSerializerPlugin : ISerializerPlugin
|
||||
{
|
||||
public string PluginName { get { return "Toshiba chmgt.db"; } }
|
||||
public string FileFilter { get { return "chmgt.db"; } }
|
||||
|
||||
public SerializerBase CreateSerializer(string inputFile)
|
||||
{
|
||||
return new DbSerializer(inputFile);
|
||||
}
|
||||
}
|
||||
}
|
||||
36
ChanSort.Loader.DbFile/Properties/AssemblyInfo.cs
Normal file
36
ChanSort.Loader.DbFile/Properties/AssemblyInfo.cs
Normal file
@@ -0,0 +1,36 @@
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
// General Information about an assembly is controlled through the following
|
||||
// set of attributes. Change these attribute values to modify the information
|
||||
// associated with an assembly.
|
||||
[assembly: AssemblyTitle("ChanSort.Loader.DbFile")]
|
||||
[assembly: AssemblyDescription("")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCompany("")]
|
||||
[assembly: AssemblyProduct("ChanSort.Loader.DbFile")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2013")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
[assembly: AssemblyCulture("")]
|
||||
|
||||
// Setting ComVisible to false makes the types in this assembly not visible
|
||||
// to COM components. If you need to access a type in this assembly from
|
||||
// COM, set the ComVisible attribute to true on that type.
|
||||
[assembly: ComVisible(false)]
|
||||
|
||||
// The following GUID is for the ID of the typelib if this project is exposed to COM
|
||||
[assembly: Guid("172c8359-67a7-4728-8463-255a972aefc0")]
|
||||
|
||||
// Version information for an assembly consists of the following four values:
|
||||
//
|
||||
// Major Version
|
||||
// Minor Version
|
||||
// Build Number
|
||||
// Revision
|
||||
//
|
||||
// You can specify all the values or you can default the Build and Revision Numbers
|
||||
// by using the '*' as shown below:
|
||||
// [assembly: AssemblyVersion("1.0.*")]
|
||||
[assembly: AssemblyVersion("1.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.0")]
|
||||
@@ -44,6 +44,18 @@
|
||||
Favorites = 5
|
||||
FavoriteNotSet = -1
|
||||
|
||||
[Series:F]
|
||||
SatDataBase.dat = 145
|
||||
TransponderDataBase.dat = 45
|
||||
PTC = 12
|
||||
map-AirA = 64
|
||||
map-AirD = 320
|
||||
map-CableD = 320
|
||||
map-SateD = 168
|
||||
map-AstraHDPlusD = 212
|
||||
Favorites = 5
|
||||
FavoriteNotSet = -1
|
||||
|
||||
[Analog:28]
|
||||
; map-AirA and map-CableA for B series
|
||||
offInUse = 0
|
||||
|
||||
@@ -117,7 +117,7 @@ namespace ChanSort.Loader.ScmFile
|
||||
}
|
||||
this.UpdateRawFavorites();
|
||||
mapping.SetFlag(_Lock, this.Lock);
|
||||
if (this.NewProgramNr == 0)
|
||||
if (this.NewProgramNr == -1)
|
||||
mapping.SetFlag(_Deleted, true);
|
||||
|
||||
this.UpdateChecksum();
|
||||
|
||||
@@ -165,6 +165,7 @@ namespace ChanSort.Loader.ScmFile
|
||||
DetectModelFromTranspoderDatabase(zip)
|
||||
};
|
||||
|
||||
// note: E and F series use an identical format, so we only care about E here
|
||||
string validCandidates = "BCDE";
|
||||
foreach (var candidateList in candidates)
|
||||
{
|
||||
@@ -364,7 +365,7 @@ namespace ChanSort.Loader.ScmFile
|
||||
for (int slotIndex = 0; slotIndex < count; slotIndex++)
|
||||
{
|
||||
DigitalChannel ci = new DigitalChannel(slotIndex, isCable, rawChannel, frequency, c.favoriteNotSetValue);
|
||||
if (ci.OldProgramNr != 0)
|
||||
if (ci.OldProgramNr != -1)
|
||||
this.DataRoot.AddChannel(list, ci);
|
||||
|
||||
rawChannel.BaseOffset += entrySize;
|
||||
|
||||
@@ -88,8 +88,9 @@ namespace ChanSort.Loader.TllFile
|
||||
public override void UpdateRawData()
|
||||
{
|
||||
mapping.SetDataPtr(this.rawData, this.baseOffset);
|
||||
mapping.SetWord(_ProgramNr, this.NewProgramNr | ((this.SignalSource & SignalSource.Radio) != 0 ? 0x4000 : 0));
|
||||
mapping.SetWord(_ProgramNr2, (mapping.GetWord(_ProgramNr2) & 0x0003) | (this.NewProgramNr << 2));
|
||||
int progNr = this.NewProgramNr == -1 ? 0 : this.NewProgramNr;
|
||||
mapping.SetWord(_ProgramNr, progNr | ((this.SignalSource & SignalSource.Radio) != 0 ? 0x4000 : 0));
|
||||
mapping.SetWord(_ProgramNr2, (mapping.GetWord(_ProgramNr2) & 0x0003) | (progNr << 2));
|
||||
if (this.IsNameModified)
|
||||
{
|
||||
mapping.SetString(_Name, this.Name, 40);
|
||||
@@ -101,7 +102,7 @@ namespace ChanSort.Loader.TllFile
|
||||
mapping.SetFlag(_Skip, this.Skip);
|
||||
mapping.SetFlag(_Lock, this.Lock);
|
||||
mapping.SetFlag(_Hide, this.Hidden);
|
||||
if (this.NewProgramNr == 0)
|
||||
if (this.NewProgramNr == -1)
|
||||
{
|
||||
mapping.SetFlag(_Deleted, true);
|
||||
mapping.SetByte("off"+_Moved, 0); //skip,lock,hide,moved
|
||||
|
||||
@@ -622,11 +622,11 @@ namespace ChanSort.Loader.TllFile
|
||||
{
|
||||
foreach (ChannelInfo channel in list.Channels)
|
||||
{
|
||||
if (channel.NewProgramNr != 0)
|
||||
if (channel.NewProgramNr != -1)
|
||||
{
|
||||
if ((channel.SignalSource & SignalSource.Digital) == 0)
|
||||
if ((channel.SignalSource & SignalSource.Analog) != 0)
|
||||
++newAnalogChannelCount;
|
||||
else if (channel.SignalSource != SignalSource.DvbS)
|
||||
else if ((channel.SignalSource & SignalSource.DvbCT) != 0)
|
||||
++newDvbctChannelCount;
|
||||
}
|
||||
channel.OldProgramNr = channel.NewProgramNr;
|
||||
|
||||
@@ -20,6 +20,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Test.Loader.TllFile", "Test
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ChanSort.Loader.ScmFile", "ChanSort.Loader.ScmFile\ChanSort.Loader.ScmFile.csproj", "{A1C9A98D-368A-44E8-9B7F-7EACA46C9EC5}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ChanSort.Loader.DbFile", "ChanSort.Loader.DbFile\ChanSort.Loader.DbFile.csproj", "{F6F02792-07F1-48D5-9AF3-F945CA5E3931}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(TestCaseManagementSettings) = postSolution
|
||||
CategoryFile = ChanSort1.vsmdi
|
||||
@@ -67,6 +69,13 @@ Global
|
||||
{A1C9A98D-368A-44E8-9B7F-7EACA46C9EC5}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{A1C9A98D-368A-44E8-9B7F-7EACA46C9EC5}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{A1C9A98D-368A-44E8-9B7F-7EACA46C9EC5}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
{F6F02792-07F1-48D5-9AF3-F945CA5E3931}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{F6F02792-07F1-48D5-9AF3-F945CA5E3931}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{F6F02792-07F1-48D5-9AF3-F945CA5E3931}.Debug|x86.ActiveCfg = Debug|x86
|
||||
{F6F02792-07F1-48D5-9AF3-F945CA5E3931}.Debug|x86.Build.0 = Debug|x86
|
||||
{F6F02792-07F1-48D5-9AF3-F945CA5E3931}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{F6F02792-07F1-48D5-9AF3-F945CA5E3931}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{F6F02792-07F1-48D5-9AF3-F945CA5E3931}.Release|x86.ActiveCfg = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
|
||||
181
ChanSort/MainForm.Designer.cs
generated
181
ChanSort/MainForm.Designer.cs
generated
@@ -45,7 +45,7 @@
|
||||
this.lblHotkeyLeft = new DevExpress.XtraEditors.LabelControl();
|
||||
this.pnlEditControls = new DevExpress.XtraEditors.PanelControl();
|
||||
this.btnToggleLock = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.globalImageCollection1 = new GlobalImageCollection(this.components);
|
||||
this.globalImageCollection1 = new ChanSort.Ui.GlobalImageCollection(this.components);
|
||||
this.btnToggleFavE = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.btnToggleFavD = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.btnToggleFavC = new DevExpress.XtraEditors.SimpleButton();
|
||||
@@ -153,6 +153,7 @@
|
||||
this.tabChannelList = new DevExpress.XtraTab.XtraTabControl();
|
||||
this.pageEmpty = new DevExpress.XtraTab.XtraTabPage();
|
||||
this.mnuContext = new DevExpress.XtraBars.PopupMenu(this.components);
|
||||
this.colOutServiceType = new DevExpress.XtraGrid.Columns.GridColumn();
|
||||
((System.ComponentModel.ISupportInitialize)(this.splitContainerControl1)).BeginInit();
|
||||
this.splitContainerControl1.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.grpOutputList)).BeginInit();
|
||||
@@ -163,7 +164,6 @@
|
||||
((System.ComponentModel.ISupportInitialize)(this.repositoryItemCheckedComboBoxEdit1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.pnlEditControls)).BeginInit();
|
||||
this.pnlEditControls.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.globalImageCollection1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.grpInputList)).BeginInit();
|
||||
this.grpInputList.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.gridRight)).BeginInit();
|
||||
@@ -190,36 +190,25 @@
|
||||
//
|
||||
resources.ApplyResources(this.splitContainerControl1, "splitContainerControl1");
|
||||
this.splitContainerControl1.Name = "splitContainerControl1";
|
||||
resources.ApplyResources(this.splitContainerControl1.Panel1, "splitContainerControl1.Panel1");
|
||||
this.splitContainerControl1.Panel1.Controls.Add(this.grpOutputList);
|
||||
resources.ApplyResources(this.splitContainerControl1.Panel2, "splitContainerControl1.Panel2");
|
||||
resources.ApplyResources(this.splitContainerControl1.Panel1, "splitContainerControl1.Panel1");
|
||||
this.splitContainerControl1.Panel2.Controls.Add(this.grpInputList);
|
||||
resources.ApplyResources(this.splitContainerControl1.Panel2, "splitContainerControl1.Panel2");
|
||||
this.splitContainerControl1.SplitterPosition = 343;
|
||||
//
|
||||
// grpOutputList
|
||||
//
|
||||
resources.ApplyResources(this.grpOutputList, "grpOutputList");
|
||||
this.grpOutputList.Controls.Add(this.gridLeft);
|
||||
this.grpOutputList.Controls.Add(this.lblHotkeyLeft);
|
||||
this.grpOutputList.Controls.Add(this.pnlEditControls);
|
||||
resources.ApplyResources(this.grpOutputList, "grpOutputList");
|
||||
this.grpOutputList.Name = "grpOutputList";
|
||||
this.grpOutputList.Enter += new System.EventHandler(this.grpOutputList_Enter);
|
||||
//
|
||||
// gridLeft
|
||||
//
|
||||
resources.ApplyResources(this.gridLeft, "gridLeft");
|
||||
this.gridLeft.DataSource = this.dsChannels;
|
||||
this.gridLeft.EmbeddedNavigator.AccessibleDescription = resources.GetString("gridLeft.EmbeddedNavigator.AccessibleDescription");
|
||||
this.gridLeft.EmbeddedNavigator.AccessibleName = resources.GetString("gridLeft.EmbeddedNavigator.AccessibleName");
|
||||
this.gridLeft.EmbeddedNavigator.AllowHtmlTextInToolTip = ((DevExpress.Utils.DefaultBoolean)(resources.GetObject("gridLeft.EmbeddedNavigator.AllowHtmlTextInToolTip")));
|
||||
this.gridLeft.EmbeddedNavigator.Anchor = ((System.Windows.Forms.AnchorStyles)(resources.GetObject("gridLeft.EmbeddedNavigator.Anchor")));
|
||||
this.gridLeft.EmbeddedNavigator.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("gridLeft.EmbeddedNavigator.BackgroundImage")));
|
||||
this.gridLeft.EmbeddedNavigator.BackgroundImageLayout = ((System.Windows.Forms.ImageLayout)(resources.GetObject("gridLeft.EmbeddedNavigator.BackgroundImageLayout")));
|
||||
this.gridLeft.EmbeddedNavigator.ImeMode = ((System.Windows.Forms.ImeMode)(resources.GetObject("gridLeft.EmbeddedNavigator.ImeMode")));
|
||||
this.gridLeft.EmbeddedNavigator.TextLocation = ((DevExpress.XtraEditors.NavigatorButtonsTextLocation)(resources.GetObject("gridLeft.EmbeddedNavigator.TextLocation")));
|
||||
this.gridLeft.EmbeddedNavigator.ToolTip = resources.GetString("gridLeft.EmbeddedNavigator.ToolTip");
|
||||
this.gridLeft.EmbeddedNavigator.ToolTipIconType = ((DevExpress.Utils.ToolTipIconType)(resources.GetObject("gridLeft.EmbeddedNavigator.ToolTipIconType")));
|
||||
this.gridLeft.EmbeddedNavigator.ToolTipTitle = resources.GetString("gridLeft.EmbeddedNavigator.ToolTipTitle");
|
||||
resources.ApplyResources(this.gridLeft, "gridLeft");
|
||||
this.gridLeft.MainView = this.gviewLeft;
|
||||
this.gridLeft.Name = "gridLeft";
|
||||
this.gridLeft.RepositoryItems.AddRange(new DevExpress.XtraEditors.Repository.RepositoryItem[] {
|
||||
@@ -234,14 +223,12 @@
|
||||
//
|
||||
// gviewLeft
|
||||
//
|
||||
this.gviewLeft.Appearance.HeaderPanel.GradientMode = ((System.Drawing.Drawing2D.LinearGradientMode)(resources.GetObject("gviewLeft.Appearance.HeaderPanel.GradientMode")));
|
||||
this.gviewLeft.Appearance.HeaderPanel.Image = ((System.Drawing.Image)(resources.GetObject("gviewLeft.Appearance.HeaderPanel.Image")));
|
||||
this.gviewLeft.Appearance.HeaderPanel.Options.UseTextOptions = true;
|
||||
this.gviewLeft.Appearance.HeaderPanel.TextOptions.WordWrap = DevExpress.Utils.WordWrap.Wrap;
|
||||
resources.ApplyResources(this.gviewLeft, "gviewLeft");
|
||||
this.gviewLeft.ColumnPanelRowHeight = 35;
|
||||
this.gviewLeft.Columns.AddRange(new DevExpress.XtraGrid.Columns.GridColumn[] {
|
||||
this.colIndex1,
|
||||
this.colOutServiceType,
|
||||
this.colOutSlot,
|
||||
this.colOutName,
|
||||
this.colOutFav,
|
||||
@@ -308,15 +295,8 @@
|
||||
new DevExpress.XtraEditors.Controls.EditorButton(((DevExpress.XtraEditors.Controls.ButtonPredefines)(resources.GetObject("repositoryItemCheckedComboBoxEdit1.Buttons"))))});
|
||||
this.repositoryItemCheckedComboBoxEdit1.CloseUpKey = new DevExpress.Utils.KeyShortcut(System.Windows.Forms.Keys.F2);
|
||||
this.repositoryItemCheckedComboBoxEdit1.ForceUpdateEditValue = DevExpress.Utils.DefaultBoolean.True;
|
||||
this.repositoryItemCheckedComboBoxEdit1.Mask.AutoComplete = ((DevExpress.XtraEditors.Mask.AutoCompleteType)(resources.GetObject("repositoryItemCheckedComboBoxEdit1.Mask.AutoComplete")));
|
||||
this.repositoryItemCheckedComboBoxEdit1.Mask.BeepOnError = ((bool)(resources.GetObject("repositoryItemCheckedComboBoxEdit1.Mask.BeepOnError")));
|
||||
this.repositoryItemCheckedComboBoxEdit1.Mask.EditMask = resources.GetString("repositoryItemCheckedComboBoxEdit1.Mask.EditMask");
|
||||
this.repositoryItemCheckedComboBoxEdit1.Mask.IgnoreMaskBlank = ((bool)(resources.GetObject("repositoryItemCheckedComboBoxEdit1.Mask.IgnoreMaskBlank")));
|
||||
this.repositoryItemCheckedComboBoxEdit1.Mask.MaskType = ((DevExpress.XtraEditors.Mask.MaskType)(resources.GetObject("repositoryItemCheckedComboBoxEdit1.Mask.MaskType")));
|
||||
this.repositoryItemCheckedComboBoxEdit1.Mask.PlaceHolder = ((char)(resources.GetObject("repositoryItemCheckedComboBoxEdit1.Mask.PlaceHolder")));
|
||||
this.repositoryItemCheckedComboBoxEdit1.Mask.SaveLiteral = ((bool)(resources.GetObject("repositoryItemCheckedComboBoxEdit1.Mask.SaveLiteral")));
|
||||
this.repositoryItemCheckedComboBoxEdit1.Mask.ShowPlaceHolders = ((bool)(resources.GetObject("repositoryItemCheckedComboBoxEdit1.Mask.ShowPlaceHolders")));
|
||||
this.repositoryItemCheckedComboBoxEdit1.Mask.UseMaskAsDisplayFormat = ((bool)(resources.GetObject("repositoryItemCheckedComboBoxEdit1.Mask.UseMaskAsDisplayFormat")));
|
||||
this.repositoryItemCheckedComboBoxEdit1.Name = "repositoryItemCheckedComboBoxEdit1";
|
||||
this.repositoryItemCheckedComboBoxEdit1.PopupSizeable = false;
|
||||
this.repositoryItemCheckedComboBoxEdit1.SelectAllItemVisible = false;
|
||||
@@ -344,7 +324,6 @@
|
||||
//
|
||||
// pnlEditControls
|
||||
//
|
||||
resources.ApplyResources(this.pnlEditControls, "pnlEditControls");
|
||||
this.pnlEditControls.Controls.Add(this.btnToggleLock);
|
||||
this.pnlEditControls.Controls.Add(this.btnToggleFavE);
|
||||
this.pnlEditControls.Controls.Add(this.btnToggleFavD);
|
||||
@@ -356,124 +335,108 @@
|
||||
this.pnlEditControls.Controls.Add(this.btnDown);
|
||||
this.pnlEditControls.Controls.Add(this.btnUp);
|
||||
this.pnlEditControls.Controls.Add(this.btnRemove);
|
||||
resources.ApplyResources(this.pnlEditControls, "pnlEditControls");
|
||||
this.pnlEditControls.Name = "pnlEditControls";
|
||||
//
|
||||
// btnToggleLock
|
||||
//
|
||||
resources.ApplyResources(this.btnToggleLock, "btnToggleLock");
|
||||
this.btnToggleLock.ImageIndex = 15;
|
||||
this.btnToggleLock.ImageList = this.globalImageCollection1;
|
||||
resources.ApplyResources(this.btnToggleLock, "btnToggleLock");
|
||||
this.btnToggleLock.Name = "btnToggleLock";
|
||||
this.btnToggleLock.Click += new System.EventHandler(this.btnToggleLock_Click);
|
||||
//
|
||||
// globalImageCollection1
|
||||
//
|
||||
this.globalImageCollection1.ParentControl = this;
|
||||
//
|
||||
// btnToggleFavE
|
||||
//
|
||||
resources.ApplyResources(this.btnToggleFavE, "btnToggleFavE");
|
||||
this.btnToggleFavE.ImageList = this.globalImageCollection1;
|
||||
resources.ApplyResources(this.btnToggleFavE, "btnToggleFavE");
|
||||
this.btnToggleFavE.Name = "btnToggleFavE";
|
||||
this.btnToggleFavE.Tag = "";
|
||||
this.btnToggleFavE.Click += new System.EventHandler(this.btnToggleFav_Click);
|
||||
//
|
||||
// btnToggleFavD
|
||||
//
|
||||
resources.ApplyResources(this.btnToggleFavD, "btnToggleFavD");
|
||||
this.btnToggleFavD.ImageList = this.globalImageCollection1;
|
||||
resources.ApplyResources(this.btnToggleFavD, "btnToggleFavD");
|
||||
this.btnToggleFavD.Name = "btnToggleFavD";
|
||||
this.btnToggleFavD.Click += new System.EventHandler(this.btnToggleFav_Click);
|
||||
//
|
||||
// btnToggleFavC
|
||||
//
|
||||
resources.ApplyResources(this.btnToggleFavC, "btnToggleFavC");
|
||||
this.btnToggleFavC.ImageList = this.globalImageCollection1;
|
||||
resources.ApplyResources(this.btnToggleFavC, "btnToggleFavC");
|
||||
this.btnToggleFavC.Name = "btnToggleFavC";
|
||||
this.btnToggleFavC.Click += new System.EventHandler(this.btnToggleFav_Click);
|
||||
//
|
||||
// btnToggleFavB
|
||||
//
|
||||
resources.ApplyResources(this.btnToggleFavB, "btnToggleFavB");
|
||||
this.btnToggleFavB.ImageList = this.globalImageCollection1;
|
||||
resources.ApplyResources(this.btnToggleFavB, "btnToggleFavB");
|
||||
this.btnToggleFavB.Name = "btnToggleFavB";
|
||||
this.btnToggleFavB.Click += new System.EventHandler(this.btnToggleFav_Click);
|
||||
//
|
||||
// btnToggleFavA
|
||||
//
|
||||
resources.ApplyResources(this.btnToggleFavA, "btnToggleFavA");
|
||||
this.btnToggleFavA.ImageList = this.globalImageCollection1;
|
||||
resources.ApplyResources(this.btnToggleFavA, "btnToggleFavA");
|
||||
this.btnToggleFavA.Name = "btnToggleFavA";
|
||||
this.btnToggleFavA.Click += new System.EventHandler(this.btnToggleFav_Click);
|
||||
//
|
||||
// btnClearLeftFilter
|
||||
//
|
||||
resources.ApplyResources(this.btnClearLeftFilter, "btnClearLeftFilter");
|
||||
this.btnClearLeftFilter.Appearance.Font = ((System.Drawing.Font)(resources.GetObject("btnClearLeftFilter.Appearance.Font")));
|
||||
this.btnClearLeftFilter.Appearance.GradientMode = ((System.Drawing.Drawing2D.LinearGradientMode)(resources.GetObject("btnClearLeftFilter.Appearance.GradientMode")));
|
||||
this.btnClearLeftFilter.Appearance.Image = ((System.Drawing.Image)(resources.GetObject("btnClearLeftFilter.Appearance.Image")));
|
||||
this.btnClearLeftFilter.Appearance.Options.UseFont = true;
|
||||
this.btnClearLeftFilter.ImageIndex = 28;
|
||||
this.btnClearLeftFilter.ImageList = this.globalImageCollection1;
|
||||
resources.ApplyResources(this.btnClearLeftFilter, "btnClearLeftFilter");
|
||||
this.btnClearLeftFilter.Name = "btnClearLeftFilter";
|
||||
this.btnClearLeftFilter.Click += new System.EventHandler(this.btnClearLeftFilter_Click);
|
||||
//
|
||||
// btnRenum
|
||||
//
|
||||
resources.ApplyResources(this.btnRenum, "btnRenum");
|
||||
this.btnRenum.ImageIndex = 22;
|
||||
this.btnRenum.ImageList = this.globalImageCollection1;
|
||||
resources.ApplyResources(this.btnRenum, "btnRenum");
|
||||
this.btnRenum.Name = "btnRenum";
|
||||
this.btnRenum.Click += new System.EventHandler(this.btnRenum_Click);
|
||||
//
|
||||
// btnDown
|
||||
//
|
||||
resources.ApplyResources(this.btnDown, "btnDown");
|
||||
this.btnDown.ImageIndex = 25;
|
||||
this.btnDown.ImageList = this.globalImageCollection1;
|
||||
resources.ApplyResources(this.btnDown, "btnDown");
|
||||
this.btnDown.Name = "btnDown";
|
||||
this.btnDown.Click += new System.EventHandler(this.btnDown_Click);
|
||||
//
|
||||
// btnUp
|
||||
//
|
||||
resources.ApplyResources(this.btnUp, "btnUp");
|
||||
this.btnUp.ImageIndex = 24;
|
||||
this.btnUp.ImageList = this.globalImageCollection1;
|
||||
resources.ApplyResources(this.btnUp, "btnUp");
|
||||
this.btnUp.Name = "btnUp";
|
||||
this.btnUp.Click += new System.EventHandler(this.btnUp_Click);
|
||||
//
|
||||
// btnRemove
|
||||
//
|
||||
resources.ApplyResources(this.btnRemove, "btnRemove");
|
||||
this.btnRemove.ImageIndex = 11;
|
||||
this.btnRemove.ImageList = this.globalImageCollection1;
|
||||
resources.ApplyResources(this.btnRemove, "btnRemove");
|
||||
this.btnRemove.Name = "btnRemove";
|
||||
this.btnRemove.Click += new System.EventHandler(this.btnRemove_Click);
|
||||
//
|
||||
// grpInputList
|
||||
//
|
||||
resources.ApplyResources(this.grpInputList, "grpInputList");
|
||||
this.grpInputList.Controls.Add(this.gridRight);
|
||||
this.grpInputList.Controls.Add(this.lblHotkeyRight);
|
||||
this.grpInputList.Controls.Add(this.panelControl3);
|
||||
resources.ApplyResources(this.grpInputList, "grpInputList");
|
||||
this.grpInputList.Name = "grpInputList";
|
||||
this.grpInputList.Enter += new System.EventHandler(this.grpInputList_Enter);
|
||||
//
|
||||
// gridRight
|
||||
//
|
||||
resources.ApplyResources(this.gridRight, "gridRight");
|
||||
this.gridRight.DataSource = this.dsChannels;
|
||||
this.gridRight.EmbeddedNavigator.AccessibleDescription = resources.GetString("gridRight.EmbeddedNavigator.AccessibleDescription");
|
||||
this.gridRight.EmbeddedNavigator.AccessibleName = resources.GetString("gridRight.EmbeddedNavigator.AccessibleName");
|
||||
this.gridRight.EmbeddedNavigator.AllowHtmlTextInToolTip = ((DevExpress.Utils.DefaultBoolean)(resources.GetObject("gridRight.EmbeddedNavigator.AllowHtmlTextInToolTip")));
|
||||
this.gridRight.EmbeddedNavigator.Anchor = ((System.Windows.Forms.AnchorStyles)(resources.GetObject("gridRight.EmbeddedNavigator.Anchor")));
|
||||
this.gridRight.EmbeddedNavigator.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("gridRight.EmbeddedNavigator.BackgroundImage")));
|
||||
this.gridRight.EmbeddedNavigator.BackgroundImageLayout = ((System.Windows.Forms.ImageLayout)(resources.GetObject("gridRight.EmbeddedNavigator.BackgroundImageLayout")));
|
||||
this.gridRight.EmbeddedNavigator.ImeMode = ((System.Windows.Forms.ImeMode)(resources.GetObject("gridRight.EmbeddedNavigator.ImeMode")));
|
||||
this.gridRight.EmbeddedNavigator.TextLocation = ((DevExpress.XtraEditors.NavigatorButtonsTextLocation)(resources.GetObject("gridRight.EmbeddedNavigator.TextLocation")));
|
||||
this.gridRight.EmbeddedNavigator.ToolTip = resources.GetString("gridRight.EmbeddedNavigator.ToolTip");
|
||||
this.gridRight.EmbeddedNavigator.ToolTipIconType = ((DevExpress.Utils.ToolTipIconType)(resources.GetObject("gridRight.EmbeddedNavigator.ToolTipIconType")));
|
||||
this.gridRight.EmbeddedNavigator.ToolTipTitle = resources.GetString("gridRight.EmbeddedNavigator.ToolTipTitle");
|
||||
resources.ApplyResources(this.gridRight, "gridRight");
|
||||
this.gridRight.MainView = this.gviewRight;
|
||||
this.gridRight.Name = "gridRight";
|
||||
this.gridRight.RepositoryItems.AddRange(new DevExpress.XtraEditors.Repository.RepositoryItem[] {
|
||||
@@ -484,11 +447,8 @@
|
||||
//
|
||||
// gviewRight
|
||||
//
|
||||
this.gviewRight.Appearance.HeaderPanel.GradientMode = ((System.Drawing.Drawing2D.LinearGradientMode)(resources.GetObject("gviewRight.Appearance.HeaderPanel.GradientMode")));
|
||||
this.gviewRight.Appearance.HeaderPanel.Image = ((System.Drawing.Image)(resources.GetObject("gviewRight.Appearance.HeaderPanel.Image")));
|
||||
this.gviewRight.Appearance.HeaderPanel.Options.UseTextOptions = true;
|
||||
this.gviewRight.Appearance.HeaderPanel.TextOptions.WordWrap = DevExpress.Utils.WordWrap.Wrap;
|
||||
resources.ApplyResources(this.gviewRight, "gviewRight");
|
||||
this.gviewRight.ColumnPanelRowHeight = 35;
|
||||
this.gviewRight.Columns.AddRange(new DevExpress.XtraGrid.Columns.GridColumn[] {
|
||||
this.colIndex,
|
||||
@@ -592,15 +552,8 @@
|
||||
new DevExpress.XtraEditors.Controls.EditorButton(((DevExpress.XtraEditors.Controls.ButtonPredefines)(resources.GetObject("repositoryItemCheckedComboBoxEdit2.Buttons"))))});
|
||||
this.repositoryItemCheckedComboBoxEdit2.CloseUpKey = new DevExpress.Utils.KeyShortcut(System.Windows.Forms.Keys.F2);
|
||||
this.repositoryItemCheckedComboBoxEdit2.ForceUpdateEditValue = DevExpress.Utils.DefaultBoolean.True;
|
||||
this.repositoryItemCheckedComboBoxEdit2.Mask.AutoComplete = ((DevExpress.XtraEditors.Mask.AutoCompleteType)(resources.GetObject("repositoryItemCheckedComboBoxEdit2.Mask.AutoComplete")));
|
||||
this.repositoryItemCheckedComboBoxEdit2.Mask.BeepOnError = ((bool)(resources.GetObject("repositoryItemCheckedComboBoxEdit2.Mask.BeepOnError")));
|
||||
this.repositoryItemCheckedComboBoxEdit2.Mask.EditMask = resources.GetString("repositoryItemCheckedComboBoxEdit2.Mask.EditMask");
|
||||
this.repositoryItemCheckedComboBoxEdit2.Mask.IgnoreMaskBlank = ((bool)(resources.GetObject("repositoryItemCheckedComboBoxEdit2.Mask.IgnoreMaskBlank")));
|
||||
this.repositoryItemCheckedComboBoxEdit2.Mask.MaskType = ((DevExpress.XtraEditors.Mask.MaskType)(resources.GetObject("repositoryItemCheckedComboBoxEdit2.Mask.MaskType")));
|
||||
this.repositoryItemCheckedComboBoxEdit2.Mask.PlaceHolder = ((char)(resources.GetObject("repositoryItemCheckedComboBoxEdit2.Mask.PlaceHolder")));
|
||||
this.repositoryItemCheckedComboBoxEdit2.Mask.SaveLiteral = ((bool)(resources.GetObject("repositoryItemCheckedComboBoxEdit2.Mask.SaveLiteral")));
|
||||
this.repositoryItemCheckedComboBoxEdit2.Mask.ShowPlaceHolders = ((bool)(resources.GetObject("repositoryItemCheckedComboBoxEdit2.Mask.ShowPlaceHolders")));
|
||||
this.repositoryItemCheckedComboBoxEdit2.Mask.UseMaskAsDisplayFormat = ((bool)(resources.GetObject("repositoryItemCheckedComboBoxEdit2.Mask.UseMaskAsDisplayFormat")));
|
||||
this.repositoryItemCheckedComboBoxEdit2.Name = "repositoryItemCheckedComboBoxEdit2";
|
||||
this.repositoryItemCheckedComboBoxEdit2.PopupSizeable = false;
|
||||
this.repositoryItemCheckedComboBoxEdit2.SelectAllItemVisible = false;
|
||||
@@ -679,10 +632,10 @@
|
||||
//
|
||||
// colServiceTypeName
|
||||
//
|
||||
resources.ApplyResources(this.colServiceTypeName, "colServiceTypeName");
|
||||
this.colServiceTypeName.FieldName = "ServiceTypeName";
|
||||
this.colServiceTypeName.Name = "colServiceTypeName";
|
||||
this.colServiceTypeName.OptionsColumn.AllowEdit = false;
|
||||
resources.ApplyResources(this.colServiceTypeName, "colServiceTypeName");
|
||||
//
|
||||
// colSatellite
|
||||
//
|
||||
@@ -742,7 +695,6 @@
|
||||
//
|
||||
// colDebug
|
||||
//
|
||||
resources.ApplyResources(this.colDebug, "colDebug");
|
||||
this.colDebug.FieldName = "Debug";
|
||||
this.colDebug.Name = "colDebug";
|
||||
this.colDebug.OptionsColumn.AllowEdit = false;
|
||||
@@ -762,10 +714,10 @@
|
||||
//
|
||||
// panelControl3
|
||||
//
|
||||
resources.ApplyResources(this.panelControl3, "panelControl3");
|
||||
this.panelControl3.Controls.Add(this.btnAddAll);
|
||||
this.panelControl3.Controls.Add(this.btnClearRightFilter);
|
||||
this.panelControl3.Controls.Add(this.btnAdd);
|
||||
resources.ApplyResources(this.panelControl3, "panelControl3");
|
||||
this.panelControl3.Name = "panelControl3";
|
||||
//
|
||||
// btnAddAll
|
||||
@@ -776,21 +728,19 @@
|
||||
//
|
||||
// btnClearRightFilter
|
||||
//
|
||||
resources.ApplyResources(this.btnClearRightFilter, "btnClearRightFilter");
|
||||
this.btnClearRightFilter.Appearance.Font = ((System.Drawing.Font)(resources.GetObject("btnClearRightFilter.Appearance.Font")));
|
||||
this.btnClearRightFilter.Appearance.GradientMode = ((System.Drawing.Drawing2D.LinearGradientMode)(resources.GetObject("btnClearRightFilter.Appearance.GradientMode")));
|
||||
this.btnClearRightFilter.Appearance.Image = ((System.Drawing.Image)(resources.GetObject("btnClearRightFilter.Appearance.Image")));
|
||||
this.btnClearRightFilter.Appearance.Options.UseFont = true;
|
||||
this.btnClearRightFilter.ImageIndex = 28;
|
||||
this.btnClearRightFilter.ImageList = this.globalImageCollection1;
|
||||
resources.ApplyResources(this.btnClearRightFilter, "btnClearRightFilter");
|
||||
this.btnClearRightFilter.Name = "btnClearRightFilter";
|
||||
this.btnClearRightFilter.Click += new System.EventHandler(this.btnClearRightFilter_Click);
|
||||
//
|
||||
// btnAdd
|
||||
//
|
||||
resources.ApplyResources(this.btnAdd, "btnAdd");
|
||||
this.btnAdd.ImageIndex = 26;
|
||||
this.btnAdd.ImageList = this.globalImageCollection1;
|
||||
resources.ApplyResources(this.btnAdd, "btnAdd");
|
||||
this.btnAdd.Name = "btnAdd";
|
||||
this.btnAdd.Click += new System.EventHandler(this.btnAdd_Click);
|
||||
//
|
||||
@@ -1185,8 +1135,8 @@
|
||||
//
|
||||
// miEnglish
|
||||
//
|
||||
resources.ApplyResources(this.miEnglish, "miEnglish");
|
||||
this.miEnglish.ButtonStyle = DevExpress.XtraBars.BarButtonStyle.Check;
|
||||
resources.ApplyResources(this.miEnglish, "miEnglish");
|
||||
this.miEnglish.CategoryGuid = new System.Guid("870e935c-f3d9-4202-9c58-87966069155d");
|
||||
this.miEnglish.Id = 2;
|
||||
this.miEnglish.ImageIndex = 0;
|
||||
@@ -1196,8 +1146,8 @@
|
||||
//
|
||||
// miGerman
|
||||
//
|
||||
resources.ApplyResources(this.miGerman, "miGerman");
|
||||
this.miGerman.ButtonStyle = DevExpress.XtraBars.BarButtonStyle.Check;
|
||||
resources.ApplyResources(this.miGerman, "miGerman");
|
||||
this.miGerman.CategoryGuid = new System.Guid("870e935c-f3d9-4202-9c58-87966069155d");
|
||||
this.miGerman.Id = 1;
|
||||
this.miGerman.ImageIndex = 1;
|
||||
@@ -1271,31 +1221,23 @@
|
||||
//
|
||||
// barDockControlTop
|
||||
//
|
||||
resources.ApplyResources(this.barDockControlTop, "barDockControlTop");
|
||||
this.barDockControlTop.Appearance.GradientMode = ((System.Drawing.Drawing2D.LinearGradientMode)(resources.GetObject("barDockControlTop.Appearance.GradientMode")));
|
||||
this.barDockControlTop.Appearance.Image = ((System.Drawing.Image)(resources.GetObject("barDockControlTop.Appearance.Image")));
|
||||
this.barDockControlTop.CausesValidation = false;
|
||||
resources.ApplyResources(this.barDockControlTop, "barDockControlTop");
|
||||
//
|
||||
// barDockControlBottom
|
||||
//
|
||||
resources.ApplyResources(this.barDockControlBottom, "barDockControlBottom");
|
||||
this.barDockControlBottom.Appearance.GradientMode = ((System.Drawing.Drawing2D.LinearGradientMode)(resources.GetObject("barDockControlBottom.Appearance.GradientMode")));
|
||||
this.barDockControlBottom.Appearance.Image = ((System.Drawing.Image)(resources.GetObject("barDockControlBottom.Appearance.Image")));
|
||||
this.barDockControlBottom.CausesValidation = false;
|
||||
resources.ApplyResources(this.barDockControlBottom, "barDockControlBottom");
|
||||
//
|
||||
// barDockControlLeft
|
||||
//
|
||||
resources.ApplyResources(this.barDockControlLeft, "barDockControlLeft");
|
||||
this.barDockControlLeft.Appearance.GradientMode = ((System.Drawing.Drawing2D.LinearGradientMode)(resources.GetObject("barDockControlLeft.Appearance.GradientMode")));
|
||||
this.barDockControlLeft.Appearance.Image = ((System.Drawing.Image)(resources.GetObject("barDockControlLeft.Appearance.Image")));
|
||||
this.barDockControlLeft.CausesValidation = false;
|
||||
resources.ApplyResources(this.barDockControlLeft, "barDockControlLeft");
|
||||
//
|
||||
// barDockControlRight
|
||||
//
|
||||
resources.ApplyResources(this.barDockControlRight, "barDockControlRight");
|
||||
this.barDockControlRight.Appearance.GradientMode = ((System.Drawing.Drawing2D.LinearGradientMode)(resources.GetObject("barDockControlRight.Appearance.GradientMode")));
|
||||
this.barDockControlRight.Appearance.Image = ((System.Drawing.Image)(resources.GetObject("barDockControlRight.Appearance.Image")));
|
||||
this.barDockControlRight.CausesValidation = false;
|
||||
resources.ApplyResources(this.barDockControlRight, "barDockControlRight");
|
||||
//
|
||||
// miMoveUp
|
||||
//
|
||||
@@ -1324,22 +1266,10 @@
|
||||
//
|
||||
resources.ApplyResources(this.txtSetSlot, "txtSetSlot");
|
||||
this.txtSetSlot.Name = "txtSetSlot";
|
||||
this.txtSetSlot.Properties.AccessibleDescription = resources.GetString("txtSetSlot.Properties.AccessibleDescription");
|
||||
this.txtSetSlot.Properties.AccessibleName = resources.GetString("txtSetSlot.Properties.AccessibleName");
|
||||
this.txtSetSlot.Properties.AutoHeight = ((bool)(resources.GetObject("txtSetSlot.Properties.AutoHeight")));
|
||||
this.txtSetSlot.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
|
||||
new DevExpress.XtraEditors.Controls.EditorButton(((DevExpress.XtraEditors.Controls.ButtonPredefines)(resources.GetObject("txtSetSlot.Properties.Buttons"))))});
|
||||
this.txtSetSlot.Properties.Mask.AutoComplete = ((DevExpress.XtraEditors.Mask.AutoCompleteType)(resources.GetObject("txtSetSlot.Properties.Mask.AutoComplete")));
|
||||
this.txtSetSlot.Properties.Mask.BeepOnError = ((bool)(resources.GetObject("txtSetSlot.Properties.Mask.BeepOnError")));
|
||||
this.txtSetSlot.Properties.Mask.EditMask = resources.GetString("txtSetSlot.Properties.Mask.EditMask");
|
||||
this.txtSetSlot.Properties.Mask.IgnoreMaskBlank = ((bool)(resources.GetObject("txtSetSlot.Properties.Mask.IgnoreMaskBlank")));
|
||||
this.txtSetSlot.Properties.Mask.MaskType = ((DevExpress.XtraEditors.Mask.MaskType)(resources.GetObject("txtSetSlot.Properties.Mask.MaskType")));
|
||||
this.txtSetSlot.Properties.Mask.PlaceHolder = ((char)(resources.GetObject("txtSetSlot.Properties.Mask.PlaceHolder")));
|
||||
this.txtSetSlot.Properties.Mask.SaveLiteral = ((bool)(resources.GetObject("txtSetSlot.Properties.Mask.SaveLiteral")));
|
||||
this.txtSetSlot.Properties.Mask.ShowPlaceHolders = ((bool)(resources.GetObject("txtSetSlot.Properties.Mask.ShowPlaceHolders")));
|
||||
this.txtSetSlot.Properties.Mask.UseMaskAsDisplayFormat = ((bool)(resources.GetObject("txtSetSlot.Properties.Mask.UseMaskAsDisplayFormat")));
|
||||
this.txtSetSlot.Properties.NullValuePrompt = resources.GetString("txtSetSlot.Properties.NullValuePrompt");
|
||||
this.txtSetSlot.Properties.NullValuePromptShowForEmptyValue = ((bool)(resources.GetObject("txtSetSlot.Properties.NullValuePromptShowForEmptyValue")));
|
||||
this.txtSetSlot.ButtonClick += new DevExpress.XtraEditors.Controls.ButtonPressedEventHandler(this.txtSetSlot_ButtonClick);
|
||||
this.txtSetSlot.EditValueChanged += new System.EventHandler(this.txtSetSlot_EditValueChanged);
|
||||
this.txtSetSlot.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txtSetSlot_KeyDown);
|
||||
@@ -1355,11 +1285,7 @@
|
||||
this.picDonate.EditValue = global::ChanSort.Ui.Properties.Resources.Donate;
|
||||
this.picDonate.MenuManager = this.barManager1;
|
||||
this.picDonate.Name = "picDonate";
|
||||
this.picDonate.Properties.AccessibleDescription = resources.GetString("picDonate.Properties.AccessibleDescription");
|
||||
this.picDonate.Properties.AccessibleName = resources.GetString("picDonate.Properties.AccessibleName");
|
||||
this.picDonate.Properties.Appearance.BackColor = ((System.Drawing.Color)(resources.GetObject("picDonate.Properties.Appearance.BackColor")));
|
||||
this.picDonate.Properties.Appearance.GradientMode = ((System.Drawing.Drawing2D.LinearGradientMode)(resources.GetObject("picDonate.Properties.Appearance.GradientMode")));
|
||||
this.picDonate.Properties.Appearance.Image = ((System.Drawing.Image)(resources.GetObject("picDonate.Properties.Appearance.Image")));
|
||||
this.picDonate.Properties.Appearance.Options.UseBackColor = true;
|
||||
this.picDonate.Properties.BorderStyle = DevExpress.XtraEditors.Controls.BorderStyles.NoBorder;
|
||||
this.picDonate.Properties.PictureAlignment = System.Drawing.ContentAlignment.TopRight;
|
||||
@@ -1371,7 +1297,6 @@
|
||||
//
|
||||
// grpTopPanel
|
||||
//
|
||||
resources.ApplyResources(this.grpTopPanel, "grpTopPanel");
|
||||
this.grpTopPanel.Controls.Add(this.rbInsertSwap);
|
||||
this.grpTopPanel.Controls.Add(this.rbInsertAfter);
|
||||
this.grpTopPanel.Controls.Add(this.rbInsertBefore);
|
||||
@@ -1382,6 +1307,7 @@
|
||||
this.grpTopPanel.Controls.Add(this.tabChannelList);
|
||||
this.grpTopPanel.Controls.Add(this.labelControl11);
|
||||
this.grpTopPanel.Controls.Add(this.txtSetSlot);
|
||||
resources.ApplyResources(this.grpTopPanel, "grpTopPanel");
|
||||
this.grpTopPanel.Name = "grpTopPanel";
|
||||
this.grpTopPanel.ShowCaption = false;
|
||||
//
|
||||
@@ -1390,18 +1316,10 @@
|
||||
resources.ApplyResources(this.rbInsertSwap, "rbInsertSwap");
|
||||
this.rbInsertSwap.MenuManager = this.barManager1;
|
||||
this.rbInsertSwap.Name = "rbInsertSwap";
|
||||
this.rbInsertSwap.Properties.AccessibleDescription = resources.GetString("rbInsertSwap.Properties.AccessibleDescription");
|
||||
this.rbInsertSwap.Properties.AccessibleName = resources.GetString("rbInsertSwap.Properties.AccessibleName");
|
||||
this.rbInsertSwap.Properties.Appearance.GradientMode = ((System.Drawing.Drawing2D.LinearGradientMode)(resources.GetObject("rbInsertSwap.Properties.Appearance.GradientMode")));
|
||||
this.rbInsertSwap.Properties.Appearance.Image = ((System.Drawing.Image)(resources.GetObject("rbInsertSwap.Properties.Appearance.Image")));
|
||||
this.rbInsertSwap.Properties.Appearance.Options.UseTextOptions = true;
|
||||
this.rbInsertSwap.Properties.Appearance.TextOptions.HAlignment = DevExpress.Utils.HorzAlignment.Far;
|
||||
this.rbInsertSwap.Properties.AutoHeight = ((bool)(resources.GetObject("rbInsertSwap.Properties.AutoHeight")));
|
||||
this.rbInsertSwap.Properties.Caption = resources.GetString("rbInsertSwap.Properties.Caption");
|
||||
this.rbInsertSwap.Properties.CheckStyle = DevExpress.XtraEditors.Controls.CheckStyles.Radio;
|
||||
this.rbInsertSwap.Properties.DisplayValueChecked = resources.GetString("rbInsertSwap.Properties.DisplayValueChecked");
|
||||
this.rbInsertSwap.Properties.DisplayValueGrayed = resources.GetString("rbInsertSwap.Properties.DisplayValueGrayed");
|
||||
this.rbInsertSwap.Properties.DisplayValueUnchecked = resources.GetString("rbInsertSwap.Properties.DisplayValueUnchecked");
|
||||
this.rbInsertSwap.Properties.GlyphAlignment = ((DevExpress.Utils.HorzAlignment)(resources.GetObject("rbInsertSwap.Properties.GlyphAlignment")));
|
||||
this.rbInsertSwap.Properties.RadioGroupIndex = 1;
|
||||
this.rbInsertSwap.TabStop = false;
|
||||
@@ -1412,14 +1330,8 @@
|
||||
resources.ApplyResources(this.rbInsertAfter, "rbInsertAfter");
|
||||
this.rbInsertAfter.MenuManager = this.barManager1;
|
||||
this.rbInsertAfter.Name = "rbInsertAfter";
|
||||
this.rbInsertAfter.Properties.AccessibleDescription = resources.GetString("rbInsertAfter.Properties.AccessibleDescription");
|
||||
this.rbInsertAfter.Properties.AccessibleName = resources.GetString("rbInsertAfter.Properties.AccessibleName");
|
||||
this.rbInsertAfter.Properties.AutoHeight = ((bool)(resources.GetObject("rbInsertAfter.Properties.AutoHeight")));
|
||||
this.rbInsertAfter.Properties.Caption = resources.GetString("rbInsertAfter.Properties.Caption");
|
||||
this.rbInsertAfter.Properties.CheckStyle = DevExpress.XtraEditors.Controls.CheckStyles.Radio;
|
||||
this.rbInsertAfter.Properties.DisplayValueChecked = resources.GetString("rbInsertAfter.Properties.DisplayValueChecked");
|
||||
this.rbInsertAfter.Properties.DisplayValueGrayed = resources.GetString("rbInsertAfter.Properties.DisplayValueGrayed");
|
||||
this.rbInsertAfter.Properties.DisplayValueUnchecked = resources.GetString("rbInsertAfter.Properties.DisplayValueUnchecked");
|
||||
this.rbInsertAfter.Properties.RadioGroupIndex = 1;
|
||||
this.rbInsertAfter.CheckedChanged += new System.EventHandler(this.rbInsertMode_CheckedChanged);
|
||||
//
|
||||
@@ -1428,14 +1340,8 @@
|
||||
resources.ApplyResources(this.rbInsertBefore, "rbInsertBefore");
|
||||
this.rbInsertBefore.MenuManager = this.barManager1;
|
||||
this.rbInsertBefore.Name = "rbInsertBefore";
|
||||
this.rbInsertBefore.Properties.AccessibleDescription = resources.GetString("rbInsertBefore.Properties.AccessibleDescription");
|
||||
this.rbInsertBefore.Properties.AccessibleName = resources.GetString("rbInsertBefore.Properties.AccessibleName");
|
||||
this.rbInsertBefore.Properties.AutoHeight = ((bool)(resources.GetObject("rbInsertBefore.Properties.AutoHeight")));
|
||||
this.rbInsertBefore.Properties.Caption = resources.GetString("rbInsertBefore.Properties.Caption");
|
||||
this.rbInsertBefore.Properties.CheckStyle = DevExpress.XtraEditors.Controls.CheckStyles.Radio;
|
||||
this.rbInsertBefore.Properties.DisplayValueChecked = resources.GetString("rbInsertBefore.Properties.DisplayValueChecked");
|
||||
this.rbInsertBefore.Properties.DisplayValueGrayed = resources.GetString("rbInsertBefore.Properties.DisplayValueGrayed");
|
||||
this.rbInsertBefore.Properties.DisplayValueUnchecked = resources.GetString("rbInsertBefore.Properties.DisplayValueUnchecked");
|
||||
this.rbInsertBefore.Properties.RadioGroupIndex = 1;
|
||||
this.rbInsertBefore.TabStop = false;
|
||||
this.rbInsertBefore.CheckedChanged += new System.EventHandler(this.rbInsertMode_CheckedChanged);
|
||||
@@ -1445,26 +1351,14 @@
|
||||
resources.ApplyResources(this.cbCloseGap, "cbCloseGap");
|
||||
this.cbCloseGap.MenuManager = this.barManager1;
|
||||
this.cbCloseGap.Name = "cbCloseGap";
|
||||
this.cbCloseGap.Properties.AccessibleDescription = resources.GetString("cbCloseGap.Properties.AccessibleDescription");
|
||||
this.cbCloseGap.Properties.AccessibleName = resources.GetString("cbCloseGap.Properties.AccessibleName");
|
||||
this.cbCloseGap.Properties.AutoHeight = ((bool)(resources.GetObject("cbCloseGap.Properties.AutoHeight")));
|
||||
this.cbCloseGap.Properties.Caption = resources.GetString("cbCloseGap.Properties.Caption");
|
||||
this.cbCloseGap.Properties.DisplayValueChecked = resources.GetString("cbCloseGap.Properties.DisplayValueChecked");
|
||||
this.cbCloseGap.Properties.DisplayValueGrayed = resources.GetString("cbCloseGap.Properties.DisplayValueGrayed");
|
||||
this.cbCloseGap.Properties.DisplayValueUnchecked = resources.GetString("cbCloseGap.Properties.DisplayValueUnchecked");
|
||||
//
|
||||
// cbAppendUnsortedChannels
|
||||
//
|
||||
resources.ApplyResources(this.cbAppendUnsortedChannels, "cbAppendUnsortedChannels");
|
||||
this.cbAppendUnsortedChannels.MenuManager = this.barManager1;
|
||||
this.cbAppendUnsortedChannels.Name = "cbAppendUnsortedChannels";
|
||||
this.cbAppendUnsortedChannels.Properties.AccessibleDescription = resources.GetString("cbAppendUnsortedChannels.Properties.AccessibleDescription");
|
||||
this.cbAppendUnsortedChannels.Properties.AccessibleName = resources.GetString("cbAppendUnsortedChannels.Properties.AccessibleName");
|
||||
this.cbAppendUnsortedChannels.Properties.AutoHeight = ((bool)(resources.GetObject("cbAppendUnsortedChannels.Properties.AutoHeight")));
|
||||
this.cbAppendUnsortedChannels.Properties.Caption = resources.GetString("cbAppendUnsortedChannels.Properties.Caption");
|
||||
this.cbAppendUnsortedChannels.Properties.DisplayValueChecked = resources.GetString("cbAppendUnsortedChannels.Properties.DisplayValueChecked");
|
||||
this.cbAppendUnsortedChannels.Properties.DisplayValueGrayed = resources.GetString("cbAppendUnsortedChannels.Properties.DisplayValueGrayed");
|
||||
this.cbAppendUnsortedChannels.Properties.DisplayValueUnchecked = resources.GetString("cbAppendUnsortedChannels.Properties.DisplayValueUnchecked");
|
||||
//
|
||||
// tabChannelList
|
||||
//
|
||||
@@ -1477,8 +1371,8 @@
|
||||
//
|
||||
// pageEmpty
|
||||
//
|
||||
resources.ApplyResources(this.pageEmpty, "pageEmpty");
|
||||
this.pageEmpty.Name = "pageEmpty";
|
||||
resources.ApplyResources(this.pageEmpty, "pageEmpty");
|
||||
//
|
||||
// mnuContext
|
||||
//
|
||||
@@ -1500,6 +1394,13 @@
|
||||
this.mnuContext.Manager = this.barManager1;
|
||||
this.mnuContext.Name = "mnuContext";
|
||||
//
|
||||
// colOutServiceType
|
||||
//
|
||||
resources.ApplyResources(this.colOutServiceType, "colOutServiceType");
|
||||
this.colOutServiceType.FieldName = "ServiceTypeName";
|
||||
this.colOutServiceType.Name = "colOutServiceType";
|
||||
this.colOutServiceType.OptionsColumn.AllowEdit = false;
|
||||
//
|
||||
// MainForm
|
||||
//
|
||||
resources.ApplyResources(this, "$this");
|
||||
@@ -1525,7 +1426,6 @@
|
||||
((System.ComponentModel.ISupportInitialize)(this.repositoryItemCheckedComboBoxEdit1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.pnlEditControls)).EndInit();
|
||||
this.pnlEditControls.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.globalImageCollection1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.grpInputList)).EndInit();
|
||||
this.grpInputList.ResumeLayout(false);
|
||||
this.grpInputList.PerformLayout();
|
||||
@@ -1676,6 +1576,7 @@
|
||||
private DevExpress.XtraEditors.SimpleButton btnToggleFavB;
|
||||
private DevExpress.XtraEditors.SimpleButton btnToggleFavA;
|
||||
private DevExpress.XtraGrid.Columns.GridColumn colOutLock;
|
||||
private DevExpress.XtraGrid.Columns.GridColumn colOutServiceType;
|
||||
private DevExpress.XtraSplashScreen.SplashScreenManager splashScreenManager1;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -17,12 +17,13 @@ using DevExpress.XtraGrid;
|
||||
using DevExpress.XtraGrid.Columns;
|
||||
using DevExpress.XtraGrid.Views.Base;
|
||||
using DevExpress.XtraGrid.Views.Grid;
|
||||
using DevExpress.XtraTab;
|
||||
|
||||
namespace ChanSort.Ui
|
||||
{
|
||||
public partial class MainForm : XtraForm
|
||||
{
|
||||
public const string AppVersion = "v2013-04-08";
|
||||
public const string AppVersion = "v2013-04-09";
|
||||
|
||||
#region enum EditMode
|
||||
private enum EditMode
|
||||
@@ -259,17 +260,21 @@ namespace ChanSort.Ui
|
||||
private void FillChannelListCombo()
|
||||
{
|
||||
this.tabChannelList.TabPages.Clear();
|
||||
bool firstNonEmpty = true;
|
||||
XtraTabPage firstNonEmpty = null;
|
||||
foreach (var list in this.dataRoot.ChannelLists)
|
||||
{
|
||||
var tab = this.tabChannelList.TabPages.Add(list.Caption);
|
||||
tab.Tag = list;
|
||||
if (firstNonEmpty && list.Count > 0)
|
||||
{
|
||||
tabChannelList.SelectedTabPage = tab;
|
||||
firstNonEmpty = false;
|
||||
}
|
||||
if (firstNonEmpty == null && list.Count > 0)
|
||||
firstNonEmpty = tab;
|
||||
}
|
||||
|
||||
if (firstNonEmpty == null)
|
||||
firstNonEmpty = tabChannelList.TabPages[0];
|
||||
if (firstNonEmpty == this.tabChannelList.SelectedTabPage)
|
||||
this.ShowChannelList((ChannelList)firstNonEmpty.Tag);
|
||||
else
|
||||
this.tabChannelList.SelectedTabPage = firstNonEmpty;
|
||||
}
|
||||
|
||||
#endregion
|
||||
@@ -314,9 +319,10 @@ namespace ChanSort.Ui
|
||||
return null;
|
||||
}
|
||||
string extension = (Path.GetExtension(inputFileName) ?? "").ToUpper();
|
||||
string upperFileName = Path.GetFileName(inputFileName).ToUpper();
|
||||
foreach (var plugin in this.plugins)
|
||||
{
|
||||
if ((plugin.FileFilter.ToUpper()+"|").Contains("*"+extension))
|
||||
if ((plugin.FileFilter.ToUpper()+"|").Contains("*"+extension) || plugin.FileFilter.ToUpper() == upperFileName)
|
||||
return plugin;
|
||||
}
|
||||
|
||||
@@ -680,7 +686,7 @@ namespace ChanSort.Ui
|
||||
maxNr = Math.Max(maxNr, channel.NewProgramNr);
|
||||
foreach (var channel in this.currentChannelList.Channels)
|
||||
{
|
||||
if (channel.NewProgramNr == 0 && !channel.IsDeleted)
|
||||
if (channel.NewProgramNr == -1 && !channel.IsDeleted)
|
||||
channel.NewProgramNr = maxNr++;
|
||||
}
|
||||
this.gviewRight.EndDataUpdate();
|
||||
@@ -875,7 +881,7 @@ namespace ChanSort.Ui
|
||||
{
|
||||
this.gviewLeft.BeginSort();
|
||||
this.gviewLeft.ClearColumnsFilter();
|
||||
this.colOutSlot.FilterInfo = new ColumnFilterInfo("[NewProgramNr]<>0");
|
||||
this.colOutSlot.FilterInfo = new ColumnFilterInfo("[NewProgramNr]<>-1");
|
||||
this.gviewLeft.EndSort();
|
||||
}
|
||||
|
||||
@@ -883,7 +889,7 @@ namespace ChanSort.Ui
|
||||
{
|
||||
this.gviewRight.BeginSort();
|
||||
this.gviewRight.ClearColumnsFilter();
|
||||
this.colSlotOld.FilterInfo = new ColumnFilterInfo("[OldProgramNr]<>0");
|
||||
this.colSlotOld.FilterInfo = new ColumnFilterInfo("[OldProgramNr]<>-1");
|
||||
this.gviewRight.EndSort();
|
||||
}
|
||||
#endregion
|
||||
@@ -892,9 +898,9 @@ namespace ChanSort.Ui
|
||||
private void LoadInputGridLayout(SignalSource newSource)
|
||||
{
|
||||
string newLayout;
|
||||
if ((newSource & SignalSource.Digital) == 0)
|
||||
if ((newSource & SignalSource.Analog) != 0)
|
||||
newLayout = Settings.Default.InputGridLayoutAnalog;
|
||||
else if (newSource == SignalSource.DvbS)
|
||||
else if ((newSource & SignalSource.DvbS) != 0)
|
||||
newLayout = Settings.Default.InputGridLayoutDvbS;
|
||||
else
|
||||
newLayout = Settings.Default.InputGridLayoutDvbCT;
|
||||
@@ -1456,7 +1462,7 @@ namespace ChanSort.Ui
|
||||
if (e.Column == this.colSlotNew)
|
||||
{
|
||||
if (!(e.Value is int)) return;
|
||||
if ((int) e.Value == 0)
|
||||
if ((int) e.Value == -1)
|
||||
e.DisplayText = string.Empty;
|
||||
}
|
||||
else if (e.Column == this.colFavorites)
|
||||
@@ -1473,12 +1479,12 @@ namespace ChanSort.Ui
|
||||
{
|
||||
ChannelInfo channel = (ChannelInfo)this.gviewRight.GetRow(e.RowHandle);
|
||||
if (channel == null) return;
|
||||
if (channel.OldProgramNr == 0)
|
||||
if (channel.OldProgramNr == -1)
|
||||
{
|
||||
e.Appearance.ForeColor = Color.Red;
|
||||
e.Appearance.Options.UseForeColor = true;
|
||||
}
|
||||
else if (channel.NewProgramNr != 0)
|
||||
else if (channel.NewProgramNr != -1)
|
||||
{
|
||||
e.Appearance.ForeColor = Color.Gray;
|
||||
e.Appearance.Options.UseForeColor = true;
|
||||
@@ -1590,7 +1596,7 @@ namespace ChanSort.Ui
|
||||
{
|
||||
var channel = (ChannelInfo)this.gviewLeft.GetRow(e.RowHandle);
|
||||
if (channel == null) return;
|
||||
if (channel.OldProgramNr == 0)
|
||||
if (channel.OldProgramNr == -1)
|
||||
{
|
||||
e.Appearance.ForeColor = Color.Red;
|
||||
e.Appearance.Options.UseForeColor = true;
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,5 +1,6 @@
|
||||
using System.Net.Sockets;
|
||||
using System.Text;
|
||||
using System.Threading;
|
||||
using ChanSort.Ui.Properties;
|
||||
using DevExpress.XtraEditors;
|
||||
|
||||
@@ -11,40 +12,45 @@ namespace ChanSort.Ui
|
||||
|
||||
public static void CheckForNewVersion()
|
||||
{
|
||||
try
|
||||
{
|
||||
var check = new UpdateCheck();
|
||||
check.Check();
|
||||
}
|
||||
catch
|
||||
{
|
||||
}
|
||||
var check = new UpdateCheck();
|
||||
Thread thread = new Thread(check.Check);
|
||||
thread.Start();
|
||||
}
|
||||
|
||||
private void Check()
|
||||
{
|
||||
try
|
||||
{
|
||||
var newVersion = this.GetLatestVersion();
|
||||
if (newVersion.CompareTo(MainForm.AppVersion.TrimStart('v')) > 0)
|
||||
this.NotifyAboutNewVersion(newVersion);
|
||||
}
|
||||
catch { }
|
||||
}
|
||||
|
||||
private string GetLatestVersion()
|
||||
{
|
||||
// NOTE: tried using WebRequest class, but that causes massive timeout problems after program start (DLL loading/init?)
|
||||
byte[] buffer = new byte[100000];
|
||||
int len;
|
||||
using (Socket sock = new Socket(AddressFamily.InterNetwork, SocketType.Stream, ProtocolType.Tcp))
|
||||
{
|
||||
sock.ReceiveTimeout = 1000;
|
||||
sock.ReceiveTimeout = 5000;
|
||||
sock.Connect("sourceforge.net", 80);
|
||||
var request = Encoding.UTF8.GetBytes("GET /projects/chansort/ HTTP/1.1\r\nHost: sourceforge.net\r\n\r\n");
|
||||
sock.Send(request);
|
||||
byte[] buffer = new byte[100000];
|
||||
int len = sock.Receive(buffer);
|
||||
var response = Encoding.ASCII.GetString(buffer, 0, len);
|
||||
int start = response.IndexOf(SearchString);
|
||||
if (start >= 0)
|
||||
{
|
||||
int end = response.IndexOf(".zip", start);
|
||||
if (end == start + SearchString.Length + 10)
|
||||
{
|
||||
string newVersion = response.Substring(start + SearchString.Length, 10);
|
||||
if (newVersion.CompareTo(MainForm.AppVersion.TrimStart('v')) > 0)
|
||||
this.NotifyAboutNewVersion(newVersion);
|
||||
}
|
||||
}
|
||||
}
|
||||
len = sock.Receive(buffer);
|
||||
}
|
||||
|
||||
var response = Encoding.ASCII.GetString(buffer, 0, len);
|
||||
int start = response.IndexOf(SearchString);
|
||||
if (start >= 0)
|
||||
{
|
||||
int end = response.IndexOf(".zip", start);
|
||||
if (end == start + SearchString.Length + 10)
|
||||
return response.Substring(start + SearchString.Length, 10);
|
||||
}
|
||||
return string.Empty;
|
||||
}
|
||||
|
||||
private void NotifyAboutNewVersion(string newVersion)
|
||||
|
||||
BIN
DLL/System.Data.SQLite.dll
Normal file
BIN
DLL/System.Data.SQLite.dll
Normal file
Binary file not shown.
5365
DLL/System.Data.SQLite.xml
Normal file
5365
DLL/System.Data.SQLite.xml
Normal file
File diff suppressed because it is too large
Load Diff
14
readme.txt
14
readme.txt
@@ -1,12 +1,14 @@
|
||||
Version v2013-04-07 ========================================================
|
||||
Version v2013-04-10a ========================================================
|
||||
|
||||
This is a maintenance release based on version v2013-04-05, which brought a
|
||||
refurbished user interface and fixes for various usability issues.
|
||||
|
||||
New:
|
||||
- Added support for Toshiba *.db channel lists (read only so far)
|
||||
- Allow Pr #0 for analog channels
|
||||
|
||||
Fixed:
|
||||
- saving a .TLL file after loading a reference list which contained channels
|
||||
that are no longer inside the .TLL caused an error during saving.
|
||||
|
||||
- first channel list only got populated after switching between tabs
|
||||
|
||||
The complete change log can be found at the end of this document
|
||||
|
||||
@@ -90,6 +92,10 @@ OTHER DEALINGS IN THE SOFTWARE.
|
||||
|
||||
Change log ====================================================================
|
||||
|
||||
2013-04-08
|
||||
- Added support for Samsung F-Series.
|
||||
- Added online check for updated program version
|
||||
|
||||
2013-04-07
|
||||
- FIX: saving a .TLL file after loading a reference list which contained channels
|
||||
that are no longer inside the .TLL caused an error during saving.
|
||||
|
||||
Reference in New Issue
Block a user