| 1693 | } |
| 1694 | |
| 1695 | void NyqBench::LoadFile() |
| 1696 | { |
| 1697 | wxString path = mPath.GetFullPath(); |
| 1698 | |
| 1699 | if (path.IsEmpty()) { |
| 1700 | return; |
| 1701 | } |
| 1702 | |
| 1703 | wxFFile f(path); |
| 1704 | if (f.IsOpened()) { |
| 1705 | wxString t; |
| 1706 | if (f.ReadAll(&t)) { |
| 1707 | //#if defined(__WXGTK__) || defined(__WXMAC__) |
| 1708 | t.Replace(wxT("\r\n"), wxT("\n")); |
| 1709 | t.Replace(wxT("\r"), wxT("\n")); |
| 1710 | //#elif defined(__WXMSW__) |
| 1711 | // t.Replace("\r\n", "\n"); |
| 1712 | //#endif |
| 1713 | mScript->SetValue(t); |
| 1714 | mScript->DiscardEdits(); |
| 1715 | } |
| 1716 | } |
| 1717 | |
| 1718 | // mScript->LoadFile(mPath.GetFullPath()); |
| 1719 | } |
| 1720 | |
| 1721 | //---------------------------------------------------------------------------- |
| 1722 | // Connects Audacity menu item to an action in this dll. |
no test coverage detected