Fix various whitespace issues

This commit is contained in:
luzpaz
2023-03-19 12:09:59 +00:00
committed by Uwe
parent 27ed6d6349
commit d5a313146f
5 changed files with 21 additions and 21 deletions

View File

@@ -295,7 +295,7 @@ class _TaskPanel:
CCX_mesh = self.fea.analysis.Document.getObject("ResultMesh")
if CCX_mesh is not None:
CCX_mesh.ViewObject.Visibility = self.CCX_mesh_visibility
def choose_working_dir(self):
wd = QtGui.QFileDialog.getExistingDirectory(None, "Choose CalculiX working directory",
self.fea.working_dir)

View File

@@ -32,9 +32,9 @@ class DrawViewDimensionTest(unittest.TestCase):
self.view1.Source = [self.document.Sphere]
self.view1.X = 220
self.view1.Y = 150
self.document.recompute()
#wait for threads to complete before checking result
loop = QtCore.QEventLoop()
@@ -53,7 +53,7 @@ class DrawViewDimensionTest(unittest.TestCase):
"""Tests if a length dimension can be added to view"""
# make length dimension
print("making length dimension")
dimension = self.document.addObject("TechDraw::DrawViewDimension", "Dimension")
self.page.addView(dimension)
dimension.Type = "Distance"

View File

@@ -6,7 +6,7 @@ def createPageWithSVGTemplate(doc=None):
"""Returns a page with an SVGTemplate added on the ActiveDocument"""
path = os.path.dirname(os.path.abspath(__file__))
templateFileSpec = path + "/TestTemplate.svg"
if not doc:
doc = FreeCAD.ActiveDocument

View File

@@ -49,8 +49,8 @@ STDAPI CreateRegistryKeys(REGKEY_SUBKEY_AND_VALUE* aKeys, ULONG cKeys);
STDAPI DeleteRegistryKeys(REGKEY_DELETEKEY* aKeys, ULONG cKeys);
BOOL APIENTRY DllMain(HINSTANCE hinstDll,
DWORD dwReason,
BOOL APIENTRY DllMain(HINSTANCE hinstDll,
DWORD dwReason,
LPVOID pvReserved)
{
switch (dwReason)
@@ -88,8 +88,8 @@ STDAPI_(ULONG) DllRelease()
STDAPI DllRegisterServer()
{
// This tells the shell to invalidate the thumbnail cache. This is important because any .recipe files
// viewed before registering this handler would otherwise show cached blank thumbnails.
// This tells the shell to invalidate the thumbnail cache. This is important because any .recipe files
// viewed before registering this handler would otherwise show cached blank thumbnails.
SHChangeNotify(SHCNE_ASSOCCHANGED, SHCNF_IDLIST, NULL, NULL);
WCHAR szModule[MAX_PATH];
@@ -101,12 +101,12 @@ STDAPI DllRegisterServer()
REGKEY_SUBKEY_AND_VALUE keys[] = {
{HKEY_CLASSES_ROOT, L"CLSID\\" szCLSID_SampleThumbnailProvider, NULL, REG_SZ, (DWORD_PTR)L"FCStd Thumbnail Provider"},
#if 1
//{HKEY_CLASSES_ROOT, L"CLSID\\DisableProcessIsolation", NULL, REG_DWORD, (DWORD) 1},
{HKEY_CLASSES_ROOT, L"CLSID\\" szCLSID_SampleThumbnailProvider, L"DisableProcessIsolation", REG_DWORD, (DWORD) 1},
//{HKEY_CLASSES_ROOT, L"CLSID\\DisableProcessIsolation", NULL, REG_DWORD, (DWORD) 1},
{HKEY_CLASSES_ROOT, L"CLSID\\" szCLSID_SampleThumbnailProvider, L"DisableProcessIsolation", REG_DWORD, (DWORD) 1},
#endif
{HKEY_CLASSES_ROOT, L"CLSID\\" szCLSID_SampleThumbnailProvider L"\\InprocServer32", NULL, REG_SZ, (DWORD_PTR)szModule},
{HKEY_CLASSES_ROOT, L"CLSID\\" szCLSID_SampleThumbnailProvider L"\\InprocServer32", L"ThreadingModel", REG_SZ, (DWORD_PTR)L"Apartment"},
//{HKEY_CLASSES_ROOT, L".FCStd\\shellex", L"Trick only here to create shellex when not existing",REG_DWORD, 1},
//{HKEY_CLASSES_ROOT, L".FCStd\\shellex", L"Trick only here to create shellex when not existing",REG_DWORD, 1},
{HKEY_CLASSES_ROOT, L".FCStd\\shellex\\{E357FCCD-A995-4576-B01F-234630154E96}", NULL, REG_SZ, (DWORD_PTR)szCLSID_SampleThumbnailProvider},
{HKEY_CLASSES_ROOT, L".FCBak\\shellex\\{E357FCCD-A995-4576-B01F-234630154E96}", NULL, REG_SZ, (DWORD_PTR)szCLSID_SampleThumbnailProvider}
};
@@ -143,7 +143,7 @@ STDAPI CreateRegistryKey(REGKEY_SUBKEY_AND_VALUE* pKey)
cbData += sizeof(WCHAR);
}
break;
default:
hr = E_INVALIDARG;
}

View File

@@ -178,7 +178,7 @@ CThumbnailProvider::~CThumbnailProvider()
STDMETHODIMP CThumbnailProvider::QueryInterface(REFIID riid,
void** ppvObject)
{
static const QITAB qit[] =
static const QITAB qit[] =
{
//QITABENT(CThumbnailProvider, IInitializeWithStream),
QITABENT(CThumbnailProvider, IInitializeWithFile),
@@ -206,16 +206,16 @@ STDMETHODIMP_(ULONG) CThumbnailProvider::Release()
}
STDMETHODIMP CThumbnailProvider::Initialize(IStream *pstm,
STDMETHODIMP CThumbnailProvider::Initialize(IStream *pstm,
DWORD grfMode)
{
return S_OK;
}
STDMETHODIMP CThumbnailProvider::Initialize(LPCWSTR pszFilePath,
STDMETHODIMP CThumbnailProvider::Initialize(LPCWSTR pszFilePath,
DWORD grfMode)
{
wcscpy_s(m_szFile, pszFilePath);
wcscpy_s(m_szFile, pszFilePath);
return S_OK;
}
@@ -235,8 +235,8 @@ bool CThumbnailProvider::CheckZip() const
return true;
}
STDMETHODIMP CThumbnailProvider::GetThumbnail(UINT cx,
HBITMAP *phbmp,
STDMETHODIMP CThumbnailProvider::GetThumbnail(UINT cx,
HBITMAP *phbmp,
WTS_ALPHATYPE *pdwAlpha)
{
try {
@@ -277,11 +277,11 @@ STDMETHODIMP CThumbnailProvider::GetThumbnail(UINT cx,
// or whatever could go wrong
}
return NOERROR;
return NOERROR;
}
STDMETHODIMP CThumbnailProvider::GetSite(REFIID riid,
STDMETHODIMP CThumbnailProvider::GetSite(REFIID riid,
void** ppvSite)
{
if (m_pSite)