Skip to content

Commit

Permalink
2019年7月1日
Browse files Browse the repository at this point in the history
  • Loading branch information
nayaku committed Jul 1, 2019
1 parent e98bfda commit b247eec
Show file tree
Hide file tree
Showing 8 changed files with 36 additions and 13 deletions.
3 changes: 3 additions & 0 deletions ImageManager/DataManager/Dao.cs
Original file line number Diff line number Diff line change
Expand Up @@ -564,6 +564,9 @@ public static void AddImages(object[,] image)
/// <param name="myImage">需要移除的图片</param>
public static void RemoveImage(MyImage myImage)
{
// 尝试删除缩略图缓冲
ImageCache.RemoveCache(myImage);

var sql = $"DELETE FROM images WHERE images.id = @myImage_id";
using (var command = new SQLiteCommand(sql, _connnect))
{
Expand Down
10 changes: 10 additions & 0 deletions ImageManager/DataManager/ImageCache.cs
Original file line number Diff line number Diff line change
Expand Up @@ -168,5 +168,15 @@ public static void ClearLoadStack()
}

}

/// <summary>
/// 删除指定路径缓存
/// </summary>
/// <param name="path"></param>
public static void RemoveCache(MyImage myImage)
{
var path = Utils.ConvertPath(myImage.Path);
_cacheDict.TryRemove(path,out var value);
}
}
}
6 changes: 3 additions & 3 deletions ImageManager/UIUnion/ImageLabelUserControl.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

18 changes: 9 additions & 9 deletions ImageManager/UIUnion/ImageUserControl.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions ImageManager/UIUnion/ImageUserControl.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
using System.ComponentModel;
using System.Diagnostics;
using System.Drawing;
using System.IO;
using System.Windows.Forms;

namespace ImageManager
Expand Down Expand Up @@ -208,6 +209,8 @@ private void CopyImageContentToolStripMenuItem_Click(object sender, EventArgs e)
private void CopyImagePathToolStripMenuItem1_Click(object sender, EventArgs e)
{
var path = Utils.ConvertPath(MyImage.Path);
if (!Path.IsPathRooted(path))
path = AppDomain.CurrentDomain.BaseDirectory + path;
Clipboard.SetText(path);
}

Expand Down
7 changes: 7 additions & 0 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,13 @@

## 更新

### 2019年7月1日更新

- 修复对某个图片删除修改后再添加,出现缓存不更新的BUG。
- 修复库图片拷贝路径路径时的返回的路径不是绝对路径的BUG。



### 2019年6月16日更新

- 折叠贴图可以缩放图片的BUG。
Expand Down
Binary file modified 打包程序/Output/素材管理器安装程序.exe
Binary file not shown.
2 changes: 1 addition & 1 deletion 打包程序/2018-7-10.iss → 打包程序/script.iss
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
; 查阅文档获取创建 INNO SETUP 脚本文件的详细资料!

#define MyAppName "素材管理器"
#define MyAppVersion "2.0.3"
#define MyAppVersion "2.0.5"
#define MyAppPublisher "NGMKS"
#define MyAppURL "im.ngmks.com"
#define MyAppExeName "ImageManager.exe"
Expand Down

0 comments on commit b247eec

Please sign in to comment.