Skip to content

Commit

Permalink
Moved file directories + WallpaperStyle = Fit
Browse files Browse the repository at this point in the history
  • Loading branch information
thepigeonfighter committed Nov 6, 2018
1 parent 4f6659f commit 789d1da
Show file tree
Hide file tree
Showing 70 changed files with 72 additions and 28 deletions.
Binary file modified .vs/AutomatedDesktopBackground/v15/.suo
Binary file not shown.
Binary file modified .vs/AutomatedDesktopBackground/v15/Server/sqlite3/storage.ide
Binary file not shown.
Binary file not shown.
Binary file not shown.
2 changes: 1 addition & 1 deletion AutomatedDesktopBackgroundUI/App.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
using System.Linq;
using System.Threading.Tasks;
using System.Windows;

[assembly: log4net.Config.XmlConfigurator(ConfigFile = "log4net.config", Watch = true)]
namespace AutomatedDesktopBackgroundUI
{
/// <summary>
Expand Down
4 changes: 2 additions & 2 deletions AutomatedDesktopBackgroundUI/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@
// 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.3.4")]
[assembly: AssemblyFileVersion("1.3.4")]
[assembly: AssemblyVersion("1.3.5")]
[assembly: AssemblyFileVersion("1.3.5")]
[assembly: NeutralResourcesLanguage("en")]


7 changes: 3 additions & 4 deletions AutomatedDesktopBackgroundUI/RootWindow.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
using System.Threading.Tasks;
using System.Windows;

[assembly: log4net.Config.XmlConfigurator(ConfigFile = "log4net.config", Watch = true)]
namespace AutomatedDesktopBackgroundUI
{
/// <summary>
Expand All @@ -20,7 +19,7 @@ public partial class RootWindow : Window
private readonly WallpaperChangeWatcher watcher = new WallpaperChangeWatcher();
public RootWindow()
{

InitializeComponent();
WindowManager.RegisterWindow(this);
this.Closing += OnApplicationClosed;
Expand All @@ -44,7 +43,7 @@ private void StartWatchingForWallpaperChanges()
catch(Exception e)
{
log.Error("Failed to start watching wallpaper file");
log.Info(e.Message);
log.Info(e.InnerException.Message);
}
}
private void OnApplicationClosed(object sender, CancelEventArgs e)
Expand All @@ -69,7 +68,7 @@ private async Task CheckForUpdates()
catch(Exception e)
{
log.Error("The update manager was not created sucessfully");
log.Info($"{e.Message.ToString()}");
log.Info($"{e.InnerException.Message.ToString()}");
}

}
Expand Down
2 changes: 1 addition & 1 deletion AutomatedDesktopBackgroundUI/SettingsWindow.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ private void WireupLists()
backgroundCombobox.ItemsSource = timeSettings;
collectionComboBox.ItemsSource = timeSettings;
SetTimes();
fileSavePathLabel.Content = StringExtensions.GetApplicationDirectory();
fileSavePathLabel.Content = InternalFileDirectorySystem.ApplicationDirectory;
}

private void BackgroundRefreshButton_Click(object sender, RoutedEventArgs e)
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
2018-11-05 21:56:36,888 [5] ERROR AutomatedDesktopBackgroundUI.RootWindow - The update manager was not created sucessfully
Binary file modified AutomatedDesktopBackgroundUI/bin/Debug/Automated Desktop.exe
Binary file not shown.
Binary file modified AutomatedDesktopBackgroundUI/bin/Debug/Automated Desktop.pdb
Binary file not shown.
Binary file not shown.
Binary file not shown.
9 changes: 4 additions & 5 deletions AutomatedDesktopBackgroundUI/bin/Debug/log4net.config
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<configSections>
<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler,log4net" />
<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler,Log4net"/>
</configSections>
<log4net>

<appender name="file" type="log4net.Appender.RollingFileAppender">
<file value="C:\Log\AutomatedDesktopLog.txt" />
<file value="${LOCALAPPDATA}\AutomatedDesktop\Data\Logs\Debug.txt" />
<appendToFile value="true" />
<rollingStyle value="Size" />
<maxSizeRollBackups value="5" />
Expand All @@ -22,7 +21,7 @@
<filter type="log4net.Filter.DenyAllFilter"/>
</appender>
<appender name="debugAppender" type="log4net.Appender.RollingFileAppender">
<file value="C:\Log\AutomatedDesktopLogFULLDEBUG.txt" />
<file value="${LOCALAPPDATA}\AutomatedDesktop\Data\Logs\FullDebug.txt" />
<appendToFile value="true" />
<rollingStyle value="Size" />
<maxSizeRollBackups value="5" />
Expand All @@ -38,7 +37,7 @@
<level value="ALL" />
<appender-ref ref="file" />
<!--Uncomment the line below to get all the information from the program-->
<!--<appender-ref ref="debugAppender"/>-->
<appender-ref ref="debugAppender"/>
</root>
</log4net>
</configuration>
Binary file modified AutomatedDesktopBackgroundUI/bin/Release/Automated Desktop.exe
Binary file not shown.
Binary file modified AutomatedDesktopBackgroundUI/bin/Release/Automated Desktop.pdb
Binary file not shown.
Binary file not shown.
Binary file not shown.
9 changes: 4 additions & 5 deletions AutomatedDesktopBackgroundUI/bin/Release/log4net.config
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<configSections>
<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler,log4net" />
<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler,Log4net"/>
</configSections>
<log4net>

<appender name="file" type="log4net.Appender.RollingFileAppender">
<file value="C:\Log\AutomatedDesktopLog.txt" />
<file value="${LOCALAPPDATA}\AutomatedDesktop\Data\Logs\Debug.txt" />
<appendToFile value="true" />
<rollingStyle value="Size" />
<maxSizeRollBackups value="5" />
Expand All @@ -22,7 +21,7 @@
<filter type="log4net.Filter.DenyAllFilter"/>
</appender>
<appender name="debugAppender" type="log4net.Appender.RollingFileAppender">
<file value="C:\Log\AutomatedDesktopLogFULLDEBUG.txt" />
<file value="${LOCALAPPDATA}\AutomatedDesktop\Data\Logs\FullDebug.txt" />
<appendToFile value="true" />
<rollingStyle value="Size" />
<maxSizeRollBackups value="5" />
Expand All @@ -38,7 +37,7 @@
<level value="ALL" />
<appender-ref ref="file" />
<!--Uncomment the line below to get all the information from the program-->
<!--<appender-ref ref="debugAppender"/>-->
<appender-ref ref="debugAppender"/>
</root>
</log4net>
</configuration>
9 changes: 4 additions & 5 deletions AutomatedDesktopBackgroundUI/log4net.config
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<configSections>
<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler,log4net" />
<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler,Log4net"/>
</configSections>
<log4net>

<appender name="file" type="log4net.Appender.RollingFileAppender">
<file value="C:\Log\AutomatedDesktopLog.txt" />
<file value="${LOCALAPPDATA}\AutomatedDesktop\Data\Logs\Debug.txt" />
<appendToFile value="true" />
<rollingStyle value="Size" />
<maxSizeRollBackups value="5" />
Expand All @@ -22,7 +21,7 @@
<filter type="log4net.Filter.DenyAllFilter"/>
</appender>
<appender name="debugAppender" type="log4net.Appender.RollingFileAppender">
<file value="C:\Log\AutomatedDesktopLogFULLDEBUG.txt" />
<file value="${LOCALAPPDATA}\AutomatedDesktop\Data\Logs\FullDebug.txt" />
<appendToFile value="true" />
<rollingStyle value="Size" />
<maxSizeRollBackups value="5" />
Expand All @@ -38,7 +37,7 @@
<level value="ALL" />
<appender-ref ref="file" />
<!--Uncomment the line below to get all the information from the program-->
<!--<appender-ref ref="debugAppender"/>-->
<appender-ref ref="debugAppender"/>
</root>
</log4net>
</configuration>
Binary file modified AutomatedDesktopBackgroundUI/obj/Debug/App.baml
Binary file not shown.
Binary file modified AutomatedDesktopBackgroundUI/obj/Debug/Automated Desktop.exe
Binary file not shown.
Binary file not shown.
Binary file modified AutomatedDesktopBackgroundUI/obj/Debug/Automated Desktop.pdb
Binary file not shown.
Binary file not shown.
Binary file modified AutomatedDesktopBackgroundUI/obj/Debug/MainWindow.baml
Binary file not shown.
Binary file modified AutomatedDesktopBackgroundUI/obj/Debug/RootWindow.baml
Binary file not shown.
Binary file modified AutomatedDesktopBackgroundUI/obj/Debug/SettingsWindow.baml
Binary file not shown.
Binary file modified AutomatedDesktopBackgroundUI/obj/Debug/WarningWindow.baml
Binary file not shown.
Binary file modified AutomatedDesktopBackgroundUI/obj/Release/App.baml
Binary file not shown.
Binary file modified AutomatedDesktopBackgroundUI/obj/Release/Automated Desktop.exe
Binary file not shown.
Binary file not shown.
Binary file modified AutomatedDesktopBackgroundUI/obj/Release/Automated Desktop.pdb
Binary file not shown.
Binary file not shown.
Binary file modified AutomatedDesktopBackgroundUI/obj/Release/MainWindow.baml
Binary file not shown.
Binary file modified AutomatedDesktopBackgroundUI/obj/Release/RootWindow.baml
Binary file not shown.
Binary file modified AutomatedDesktopBackgroundUI/obj/Release/SettingsWindow.baml
Binary file not shown.
Binary file modified AutomatedDesktopBackgroundUI/obj/Release/WarningWindow.baml
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ private static string FileSavePath
get
{
string baseUrl = Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData);
string fullUrl = baseUrl + @"\DesktopBackgrounds";
string fullUrl = baseUrl + @"\AutomatedDesktop\Data";
return Directory.CreateDirectory(fullUrl).FullName;
}
set { FileSavePath = value; }
Expand Down
4 changes: 2 additions & 2 deletions AutomatedDesktopBackground_Library/Jobs/BackGroundPicker.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,14 @@ public void PickRandomBackground(bool inAppRequest)
{
string imageUrl = GetImageFileDir();
DataKeeper.UpdateWallpaper(imageUrl);
WallpaperSetter.Set(imageUrl, WallpaperSetter.Style.Stretched);
WallpaperSetter.Set(imageUrl, WallpaperSetter.Style.Fit);
}
}
else
{
string imageUrl = GetImageFileDir();
DataKeeper.UpdateWallpaper(imageUrl);
WallpaperSetter.Set(imageUrl, WallpaperSetter.Style.Stretched);
WallpaperSetter.Set(imageUrl, WallpaperSetter.Style.Fit);
string[] lines = new string[]{$"{imageUrl}","This is a temp file", "that alerts a file watcher " , "To update the application data"};
File.WriteAllLines(InternalFileDirectorySystem.WallpaperCacheFile, lines);
}
Expand Down
8 changes: 7 additions & 1 deletion AutomatedDesktopBackground_Library/Jobs/WallpaperSetter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@ public enum Style : int
{
Tiled,
Centered,
Stretched
Stretched,
Fit
}

public static void Set(string url, Style style)
Expand Down Expand Up @@ -52,6 +53,11 @@ public static void Set(string url, Style style)
key.SetValue("WallpaperStyle", 1.ToString());
key.SetValue("TileWallpaper", 1.ToString());
}
if (style == Style.Fit)
{
key.SetValue("WallpaperStyle", 3.ToString());
key.SetValue("TileWallpaper", 0.ToString());
}

SystemParametersInfo(SPI_SETDESKWALLPAPER,
0,
Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified ChangeBackgroundOnce/bin/Debug/ChangeBackgroundOnce.exe
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified ChangeBackgroundOnce/obj/Debug/ChangeBackgroundOnce.exe
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified CreateMenuContext/bin/Release/AutomatedDesktopBackgroundLibrary.dll
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed Releases/AutomatedDesktop-1.3.4-delta.nupkg
Binary file not shown.
Binary file added Releases/AutomatedDesktop-1.3.5-delta.nupkg
Binary file not shown.
Binary file not shown.
4 changes: 3 additions & 1 deletion Releases/RELEASES
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,6 @@ C6461EC786941EC20D58C98731FC2D39A881C0B5 AutomatedDesktop-1.3.1-delta.nupkg 1468
13B077E527B67FA15B2B783DDDA6E293207BCC1C AutomatedDesktop-1.3.2-delta.nupkg 138285
A93952CF7B7A24C2BF464B6F2AF3E971B1D1F7BF AutomatedDesktop-1.3.2-full.nupkg 1559750
A58B59136B8964EC7C6B02AEB5F2D22E7A43E2E1 AutomatedDesktop-1.3.4-delta.nupkg 103049
D04A3ACA35241CC50A3216AE0ECF0E8AB2121F59 AutomatedDesktop-1.3.4-full.nupkg 1632545
D04A3ACA35241CC50A3216AE0ECF0E8AB2121F59 AutomatedDesktop-1.3.4-full.nupkg 1632545
3BD94AD3DA21847EDA56C38DA4021724569B3975 AutomatedDesktop-1.3.5-delta.nupkg 18986
3F5F7A71B80E470BC87D00932A14C8DA002BB9EB AutomatedDesktop-1.3.5-full.nupkg 1632592
Binary file modified Releases/Setup.exe
Binary file not shown.
Binary file modified Releases/Setup.msi
Binary file not shown.
39 changes: 39 additions & 0 deletions packages/squirrel.windows.1.9.0/tools/SquirrelSetup.log
Original file line number Diff line number Diff line change
Expand Up @@ -682,3 +682,42 @@ Usage: WriteZipToSetup [Setup.exe template] [Zip File]
2018-11-04 22:29:07> DeltaPackageBuilder: \lib\net45\Images\RoundedSquare.png not found in base package, marking as new
2018-11-04 22:29:07> DeltaPackageBuilder: \lib\net45\Images\Settings Button2.png not found in base package, marking as new
2018-11-04 22:29:08> Program: Building embedded zip file for Setup.exe
2018-11-05 22:17:59> Program: Starting Squirrel Updater: --releasify C:\TempRelease\AutomatedDesktop.1.3.5.nupkg
2018-11-05 22:17:59> Program: Bootstrapper EXE found at:F:\Users\georg\source\repos\AutomatedDesktopBackground\packages\squirrel.windows.1.9.0\tools\Setup.exe
2018-11-05 22:17:59> Program: Creating release package: F:\Users\georg\source\repos\AutomatedDesktopBackground\Releases\AutomatedDesktop.1.3.5.nupkg
2018-11-05 22:17:59> ReleasePackage: Creating release package: F:\Users\georg\source\repos\AutomatedDesktopBackground\Releases\AutomatedDesktop.1.3.5.nupkg => F:\Users\georg\source\repos\AutomatedDesktopBackground\Releases\AutomatedDesktop-1.3.5-full.nupkg
2018-11-05 22:18:00> ReleasePackage: Extracting dependent packages: []
2018-11-05 22:18:00> ReleasePackage: Removing unnecessary data
2018-11-05 22:18:00> ReleasePackage: No release notes found in C:\Users\thepigeonfighter\AppData\Local\SquirrelTemp\tempa\AutomatedDesktop.nuspec
2018-11-05 22:18:00> DeltaPackageBuilder: Extracting .\Releases\AutomatedDesktop-1.3.4-full.nupkg and F:\Users\georg\source\repos\AutomatedDesktopBackground\Releases\AutomatedDesktop-1.3.5-full.nupkg into C:\Users\thepigeonfighter\AppData\Local\SquirrelTemp\tempb
2018-11-05 22:18:01> DeltaPackageBuilder: Delta patching C:\Users\thepigeonfighter\AppData\Local\SquirrelTemp\tempa\lib\net45\Automated Desktop.exe => C:\Users\thepigeonfighter\AppData\Local\SquirrelTemp\tempb\lib\net45\Automated Desktop.exe
2018-11-05 22:18:02> DeltaPackageBuilder: \lib\net45\Automated Desktop.exe.config hasn't changed, writing dummy file
2018-11-05 22:18:02> DeltaPackageBuilder: Delta patching C:\Users\thepigeonfighter\AppData\Local\SquirrelTemp\tempa\lib\net45\Automated Desktop_ExecutionStub.exe => C:\Users\thepigeonfighter\AppData\Local\SquirrelTemp\tempb\lib\net45\Automated Desktop_ExecutionStub.exe
2018-11-05 22:18:02> DeltaPackageBuilder: Delta patching C:\Users\thepigeonfighter\AppData\Local\SquirrelTemp\tempa\lib\net45\AutomatedDesktopBackgroundLibrary.dll => C:\Users\thepigeonfighter\AppData\Local\SquirrelTemp\tempb\lib\net45\AutomatedDesktopBackgroundLibrary.dll
2018-11-05 22:18:02> DeltaPackageBuilder: \lib\net45\DeltaCompressionDotNet.dll hasn't changed, writing dummy file
2018-11-05 22:18:02> DeltaPackageBuilder: \lib\net45\DeltaCompressionDotNet.MsDelta.dll hasn't changed, writing dummy file
2018-11-05 22:18:02> DeltaPackageBuilder: \lib\net45\DeltaCompressionDotNet.PatchApi.dll hasn't changed, writing dummy file
2018-11-05 22:18:02> DeltaPackageBuilder: Delta patching C:\Users\thepigeonfighter\AppData\Local\SquirrelTemp\tempa\lib\net45\log4net.config => C:\Users\thepigeonfighter\AppData\Local\SquirrelTemp\tempb\lib\net45\log4net.config
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\log4net.dll hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\Mono.Cecil.dll hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\Mono.Cecil.Mdb.dll hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\Mono.Cecil.Pdb.dll hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\Mono.Cecil.Rocks.dll hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\Newtonsoft.Json.dll hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\NuGet.Squirrel.dll hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\PexelsNet.dll hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\Quartz.dll hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\SharpCompress.dll hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\Splat.dll hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\Squirrel.dll hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\Images\Background Pane.png hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\Images\Background Pane_WBorder.png hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\Images\Border.png hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\Images\CloseButton.png hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\Images\Icon.ico hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\Images\MainWindowPane.png hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\Images\minimize button.png hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\Images\NextImageButton.png hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\Images\RoundedSquare.png hasn't changed, writing dummy file
2018-11-05 22:18:03> DeltaPackageBuilder: \lib\net45\Images\Settings Button2.png hasn't changed, writing dummy file
2018-11-05 22:18:03> Program: Building embedded zip file for Setup.exe

0 comments on commit 789d1da

Please sign in to comment.