Browse Source

Merge remote-tracking branch 'origin/zhangxueyang' into zyy

解决冲突
# Conflicts:
#	XHWK.WKTool/PrintWindow.xaml.cs
tags/录制修改前
耀 4 years ago
parent
commit
f52098756b

+ 3
- 3
XHWK.WKTool/App.config View File

5
   </startup>
5
   </startup>
6
   <appSettings>
6
   <appSettings>
7
     <!--0正式 1测试-->
7
     <!--0正式 1测试-->
8
-    <add key="IsDebug" value="1" />
8
+    <add key="IsDebug" value="0" />
9
     <add key="OutputVideoLog" value="0"/>
9
     <add key="OutputVideoLog" value="0"/>
10
     <!--图片压缩等级-->
10
     <!--图片压缩等级-->
11
     <add key="ImageCompressionLevel" value="30" />
11
     <add key="ImageCompressionLevel" value="30" />
34
     <!--上传每片大小 Mb-->
34
     <!--上传每片大小 Mb-->
35
     <add key="UploadSliceLen" value="1" />
35
     <add key="UploadSliceLen" value="1" />
36
     <!--版本号-->
36
     <!--版本号-->
37
-    <add key="VersionCode" value="35" />
38
-    <add key="VersionName" value="1.3.4" />
37
+    <add key="VersionCode" value="37" />
38
+    <add key="VersionName" value="1.3.6" />
39
     <add key="ClientSettingsProvider.ServiceUri" value="" />
39
     <add key="ClientSettingsProvider.ServiceUri" value="" />
40
   </appSettings>
40
   </appSettings>
41
   <system.web>
41
   <system.web>

+ 10
- 10
XHWK.WKTool/App.cs View File

243
                 //}
243
                 //}
244
                 #endregion
244
                 #endregion
245
 
245
 
246
-                //try
247
-                //{
248
-                //    if(Directory.Exists(AppDomain.CurrentDomain.BaseDirectory+"temp"))//清除临时文件
249
-                //    {
250
-                //        Directory.Delete(AppDomain.CurrentDomain.BaseDirectory + "temp",true);
251
-                //    }
252
-                //}
253
-                //catch (Exception)
254
-                //{
255
-                //}
246
+                try
247
+                {
248
+                    if (Directory.Exists(AppDomain.CurrentDomain.BaseDirectory + "temp"))//清除临时文件
249
+                    {
250
+                        Directory.Delete(AppDomain.CurrentDomain.BaseDirectory + "temp", true);
251
+                    }
252
+                }
253
+                catch (Exception)
254
+                {
255
+                }
256
 
256
 
257
                 //如果本地文件为空,弹出弹窗 输密匙
257
                 //如果本地文件为空,弹出弹窗 输密匙
258
                 //本地文件不为空, 解析
258
                 //本地文件不为空, 解析

+ 16
- 13
XHWK.WKTool/PrintWindow.xaml.cs View File

98
             //FileToolsCommon.CreateFile(imgPath);
98
             //FileToolsCommon.CreateFile(imgPath);
99
             //string pdf = imgPath + "\\101.pdf";
99
             //string pdf = imgPath + "\\101.pdf";
100
             //PDF位置
100
             //PDF位置
101
-            string SourcePath = FileToolsCommon.GetFileAbsolutePath("/temp/101.pdf");
102
-            StrList.Add(SourcePath);
101
+            //string SourcePath = FileToolsCommon.GetFileAbsolutePath("/temp/101.pdf");
102
+            //StrList.Add(SourcePath);
103
+            int ipdf = 102;
104
+            string imgPath = FileToolsCommon.GetFileAbsolutePath("temp/");
105
+            string tempImgPath = imgPath;
106
+            imgPath += "101.pdf";
107
+            while (File.Exists(imgPath))
108
+            {
109
+                imgPath = tempImgPath + ipdf.ToString() + ".pdf";
110
+                ipdf++;
111
+            }
112
+            StrList.Add(imgPath);
103
             //打印数量
113
             //打印数量
104
             int PrinterNum = Convert.ToInt32(txbNumberOfCopies.Text);
114
             int PrinterNum = Convert.ToInt32(txbNumberOfCopies.Text);
105
             StrList.Add(PrinterNum.ToString());
115
             StrList.Add(PrinterNum.ToString());
151
                 //iTextSharp.text.Rectangle page = new iTextSharp.text.Rectangle(iTextSharp.text.PageSize.A4., 250f);//cs
161
                 //iTextSharp.text.Rectangle page = new iTextSharp.text.Rectangle(iTextSharp.text.PageSize.A4., 250f);//cs
152
                 ////设置纸张横向
162
                 ////设置纸张横向
153
                 //document.SetPageSize(iTextSharp.text.PageSize.A4.Rotate());
163
                 //document.SetPageSize(iTextSharp.text.PageSize.A4.Rotate());
154
-                int ipdf = 102;
155
-                string imgPath = FileToolsCommon.GetFileAbsolutePath("temp/");
156
-                string tempImgPath = imgPath;
157
-                FileToolsCommon.CreateDirectory(imgPath);
158
-                imgPath += "101.pdf";
159
-                while (File.Exists(imgPath))
160
-                {
161
-                    imgPath = tempImgPath + ipdf.ToString() + ".pdf";
162
-                    ipdf++;
163
-                }
164
-                iTextSharp.text.pdf.PdfWriter.GetInstance(document, new FileStream(imgPath, FileMode.Create, FileAccess.ReadWrite));
164
+
165
+                List<string> objStr1 = (List<string>)obj;
166
+                string SourcePath1 = objStr1[0];
167
+                iTextSharp.text.pdf.PdfWriter.GetInstance(document, new FileStream(SourcePath1, FileMode.Create, FileAccess.ReadWrite));
165
                 document.Open();
168
                 document.Open();
166
                 iTextSharp.text.Image image;
169
                 iTextSharp.text.Image image;
167
                 for (int i = 0; i < APP.PageDrawList.Count; i++)
170
                 for (int i = 0; i < APP.PageDrawList.Count; i++)

+ 2
- 2
XHWK.WKTool/Properties/AssemblyInfo.cs View File

49
 //可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值
49
 //可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值
50
 //通过使用 "*",如下所示:
50
 //通过使用 "*",如下所示:
51
 // [assembly: AssemblyVersion("1.0.*")]
51
 // [assembly: AssemblyVersion("1.0.*")]
52
-[assembly: AssemblyVersion("1.3.4.0")]
53
-[assembly: AssemblyFileVersion("1.3.4.0")]
52
+[assembly: AssemblyVersion("1.3.6.0")]
53
+[assembly: AssemblyFileVersion("1.3.6.0")]

+ 6
- 0
XHWK.WKTool/XHMicroLessonSystemWindow.xaml.cs View File

185
         public void Initialize()
185
         public void Initialize()
186
         {
186
         {
187
             #region 数据初始化
187
             #region 数据初始化
188
+            string pathTemp = AppDomain.CurrentDomain.BaseDirectory + "Temp\\";
189
+            FileToolsCommon.CreateDirectory(pathTemp);
188
             APP.pageData.pagenum = 0;
190
             APP.pageData.pagenum = 0;
189
             APP.pageData.currpage = APP.pageData.pagenum;
191
             APP.pageData.currpage = APP.pageData.pagenum;
190
             btnStop.IsEnabled = false;//停止录制按钮不可点击
192
             btnStop.IsEnabled = false;//停止录制按钮不可点击
3579
             imgCanvas.Source = null;
3581
             imgCanvas.Source = null;
3580
             imgDocumentation.Source = null;
3582
             imgDocumentation.Source = null;
3581
             imgPPT.Source = null;
3583
             imgPPT.Source = null;
3584
+            if(APP.pageData.pagenum == 1)
3585
+            {
3586
+                APP.PageDrawList = new List<Model_DrawData>();
3587
+            }
3582
             ///画板模型增加一页
3588
             ///画板模型增加一页
3583
             Model_DrawData model_DrawData = new Model_DrawData
3589
             Model_DrawData model_DrawData = new Model_DrawData
3584
             {
3590
             {

Loading…
Cancel
Save